#1F218E#1F218E

#1F218E is a dark, vivid blue. Relative luminance 0.033; OKLCH L 33.8% C 0.173 H 271.6°. Best body text is #FFFFFF at 12.60:1 contrast (WCAG AA passes).

Color values

HEX#1F218E
RGBrgb(31, 33, 142)
HSLhsl(239, 64%, 34%)
HSVhsv(239, 78%, 56%)
CMYKcmyk(78.2%, 76.8%, 0%, 44.3%)
CIE-LABlab(21.32, 38.09, -59.59)
CIE-LCHlch(21.32, 70.72, 302.59°)
OKLaboklab(33.79% 0.0049 -0.1725)
OKLCHoklch(33.79% 0.173 271.6)
XYZxyz(5.9898, 3.3314, 25.9133)
Luminance0.0333 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F218E #8E8C1F
analogous
#1F598E #1F218E #551F8E
triadic
#1F218E #8E1F21 #218E1F
tetradic
#1F218E #8E1F59 #8E8C1F #1F8E55
square
#1F218E #8E1F59 #8E8C1F #1F8E55
split-complementary
#1F218E #8E551F #598E1F
monochromatic
#090A2A #14155C #1F218E #2A2DC0 #4F51D9

Accessibility & contrast

On white

12.60
#1F218E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.67
#1F218E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F218E
12.60:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F218E#FFFFFF#000000##FFFFFF
##1F218E1.0012.601.6712.60
#FFFFFF12.601.0021.001.00
#0000001.6721.001.0021.00
##FFFFFF12.601.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003991
Deuteranopia (green-blind)
#002E8C
Tritanopia (blue-blind)
#004156
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #1f218e;
/* rgb */ color: rgb(31, 33, 142);
/* oklch */ color: oklch(33.8% 0.173 271.6);
Tailwind
colors: {
  custom: {
    50: '#6f5eb0',
    500: '#1f218e',
    950: '#000000',
  },
}
SCSS
$custom: #1f218e;
$custom-light: #6f5eb0;
$custom-dark: #000000;
JSON
{
  "hex": "#1f218e",
  "rgb": {
    "r": 31,
    "g": 33,
    "b": 142
  },
  "hsl": {
    "h": 238.919,
    "s": 64.162,
    "l": 33.922
  },
  "oklch": {
    "l": 0.33795,
    "c": 0.17258,
    "h": 271.6
  },
  "luminance": 0.03332
}

Semantic roles & 50–950 ramp

primary
#1F218E
secondary
#BBB94D
accent
#E441E7
background
#F7F5FB
surface
#EDE9F6
border
#C8C5D0
text
#090411
muted
#7B7980

Preview Lab

Preview with #1F218E

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

Preview Lab → · Contrast checker → · Palette generator →

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