#1F1F87#1F1F87

#1F1F87 is a dark, vivid blue. Relative luminance 0.030; OKLCH L 32.7% C 0.166 H 272.4°. Best body text is #FFFFFF at 13.09:1 contrast (WCAG AA passes).

Color values

HEX#1F1F87
RGBrgb(31, 31, 135)
HSLhsl(240, 63%, 33%)
HSVhsv(240, 77%, 53%)
CMYKcmyk(77%, 77%, 0%, 47.1%)
CIE-LABlab(20.12, 36.83, -57.20)
CIE-LCHlch(20.12, 68.03, 302.78°)
OKLaboklab(32.71% 0.0071 -0.1655)
OKLCHoklch(32.71% 0.166 272.4)
XYZxyz(5.4268, 3.0200, 23.2139)
Luminance0.0302 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F1F87 #87871F
analogous
#1F5387 #1F1F87 #531F87
triadic
#1F1F87 #871F1F #1F871F
tetradic
#1F1F87 #871F53 #87871F #1F8753
square
#1F1F87 #871F53 #87871F #1F8753
split-complementary
#1F1F87 #87531F #53871F
monochromatic
#080823 #141455 #1F1F87 #2A2AB9 #4B4BD6

Accessibility & contrast

On white

13.09
#1F1F87 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.60
#1F1F87 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F1F87
13.09:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F1F87#FFFFFF#000000##FFFFFF
##1F1F871.0013.091.6013.09
#FFFFFF13.091.0021.001.00
#0000001.6021.001.0021.00
##FFFFFF13.091.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00368A
Deuteranopia (green-blind)
#002B85
Tritanopia (blue-blind)
#003E51
Achromatopsia (no color)
#313131

Design tokens & code

CSS
--color: #1f1f87;
/* rgb */ color: rgb(31, 31, 135);
/* oklch */ color: oklch(32.7% 0.166 272.4);
Tailwind
colors: {
  custom: {
    50: '#6d5cab',
    500: '#1f1f87',
    950: '#000000',
  },
}
SCSS
$custom: #1f1f87;
$custom-light: #6d5cab;
$custom-dark: #000000;
JSON
{
  "hex": "#1f1f87",
  "rgb": {
    "r": 31,
    "g": 31,
    "b": 135
  },
  "hsl": {
    "h": 240,
    "s": 62.651,
    "l": 32.549
  },
  "oklch": {
    "l": 0.32711,
    "c": 0.16569,
    "h": 272.4
  },
  "luminance": 0.03021
}

Semantic roles & 50–950 ramp

primary
#1F1F87
secondary
#B8B84A
accent
#E642E6
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#080410
muted
#7B797F

Preview Lab

Preview with #1F1F87

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

Preview Lab → · Contrast checker → · Palette generator →

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