#21218B#21218B

#21218B is a dark, vivid blue. Relative luminance 0.033; OKLCH L 33.6% C 0.168 H 272.7°. Best body text is #FFFFFF at 12.69:1 contrast (WCAG AA passes).

Color values

HEX#21218B
RGBrgb(33, 33, 139)
HSLhsl(240, 62%, 34%)
HSVhsv(240, 76%, 55%)
CMYKcmyk(76.3%, 76.3%, 0%, 45.5%)
CIE-LABlab(21.11, 37.22, -58.07)
CIE-LCHlch(21.11, 68.97, 302.66°)
OKLaboklab(33.58% 0.0078 -0.168)
OKLCHoklch(33.58% 0.168 272.7)
XYZxyz(5.8297, 3.2745, 24.7459)
Luminance0.0328 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#21218B #8B8B21
analogous
#21568B #21218B #56218B
triadic
#21218B #8B2121 #218B21
tetradic
#21218B #8B2156 #8B8B21 #218B56
square
#21218B #8B2156 #8B8B21 #218B56
split-complementary
#21218B #8B5621 #568B21
monochromatic
#0A0A28 #15155A #21218B #2D2DBC #5151D6

Accessibility & contrast

On white

12.69
#21218B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.66
#21218B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #21218B
12.69:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##21218B#FFFFFF#000000##FFFFFF
##21218B1.0012.691.6612.69
#FFFFFF12.691.0021.001.00
#0000001.6621.001.0021.00
##FFFFFF12.691.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00388E
Deuteranopia (green-blind)
#002D89
Tritanopia (blue-blind)
#004054
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #21218b;
/* rgb */ color: rgb(33, 33, 139);
/* oklch */ color: oklch(33.6% 0.168 272.7);
Tailwind
colors: {
  custom: {
    50: '#6f5eae',
    500: '#21218b',
    950: '#000000',
  },
}
SCSS
$custom: #21218b;
$custom-light: #6f5eae;
$custom-dark: #000000;
JSON
{
  "hex": "#21218b",
  "rgb": {
    "r": 33,
    "g": 33,
    "b": 139
  },
  "hsl": {
    "h": 240,
    "s": 61.628,
    "l": 33.725
  },
  "oklch": {
    "l": 0.33577,
    "c": 0.16822,
    "h": 272.7
  },
  "luminance": 0.03275
}

Semantic roles & 50–950 ramp

primary
#21218B
secondary
#B9B94F
accent
#E543E5
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#090410
muted
#7B797F

Preview Lab

Preview with #21218B

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

Preview Lab → · Contrast checker → · Palette generator →

#21218B Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva