#1F3797#1F3797

#1F3797 is a dark, vivid blue. Relative luminance 0.053; OKLCH L 38.5% C 0.159 H 267.3°. Best body text is #FFFFFF at 10.24:1 contrast (WCAG AA passes).

Color values

HEX#1F3797
RGBrgb(31, 55, 151)
HSLhsl(228, 66%, 36%)
HSVhsv(228, 79%, 59%)
CMYKcmyk(79.5%, 63.6%, 0%, 40.8%)
CIE-LABlab(27.46, 27.30, -55.06)
CIE-LCHlch(27.46, 61.46, 296.37°)
OKLaboklab(38.51% -0.0076 -0.1593)
OKLCHoklch(38.51% 0.159 267.3)
XYZxyz(7.5152, 5.2572, 29.8908)
Luminance0.0526 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F3797 #977F1F
analogous
#1F7397 #1F3797 #431F97
triadic
#1F3797 #971F37 #37971F
tetradic
#1F3797 #971F73 #977F1F #1F9743
square
#1F3797 #971F73 #977F1F #1F9743
split-complementary
#1F3797 #97431F #73971F
monochromatic
#0A1231 #152564 #1F3797 #2949CA #5470DC

Accessibility & contrast

On white

10.24
#1F3797 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.05
#1F3797 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F3797
10.24:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F3797#FFFFFF#000000##FFFFFF
##1F37971.0010.242.0510.24
#FFFFFF10.241.0021.001.00
#0000002.0521.001.0021.00
##FFFFFF10.241.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00479A
Deuteranopia (green-blind)
#003B95
Tritanopia (blue-blind)
#005061
Achromatopsia (no color)
#414141

Design tokens & code

CSS
--color: #1f3797;
/* rgb */ color: rgb(31, 55, 151);
/* oklch */ color: oklch(38.5% 0.159 267.3);
Tailwind
colors: {
  custom: {
    50: '#6f6db6',
    500: '#1f3797',
    950: '#000000',
  },
}
SCSS
$custom: #1f3797;
$custom-light: #6f6db6;
$custom-dark: #000000;
JSON
{
  "hex": "#1f3797",
  "rgb": {
    "r": 31,
    "g": 55,
    "b": 151
  },
  "hsl": {
    "h": 228,
    "s": 65.934,
    "l": 35.686
  },
  "oklch": {
    "l": 0.38513,
    "c": 0.15944,
    "h": 267.3
  },
  "luminance": 0.05258
}

Semantic roles & 50–950 ramp

primary
#1F3797
secondary
#BFAA52
accent
#C73FE9
background
#F7F6FB
surface
#EDEBF6
border
#C8C6D0
text
#090711
muted
#7B7A80

Preview Lab

Preview with #1F3797

Body copy rendered with the generated semantic roles for this colour.

Preview Lab → · Contrast checker → · Palette generator →

#1F3797 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva