#212A7E#212A7E

#212A7E is a dark, vivid blue. Relative luminance 0.035; OKLCH L 33.7% C 0.141 H 271.7°. Best body text is #FFFFFF at 12.37:1 contrast (WCAG AA passes).

Color values

HEX#212A7E
RGBrgb(33, 42, 126)
HSLhsl(234, 58%, 31%)
HSVhsv(234, 74%, 49%)
CMYKcmyk(73.8%, 66.7%, 0%, 50.6%)
CIE-LABlab(21.89, 26.73, -48.61)
CIE-LCHlch(21.89, 55.48, 298.81°)
OKLaboklab(33.74% 0.0041 -0.1404)
OKLCHoklch(33.74% 0.141 271.7)
XYZxyz(5.2198, 3.4851, 20.1322)
Luminance0.0349 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#212A7E #7E7521
analogous
#21587E #212A7E #46217E
triadic
#212A7E #7E212A #2A7E21
tetradic
#212A7E #7E2158 #7E7521 #217E46
square
#212A7E #7E2158 #7E7521 #217E46
split-complementary
#212A7E #7E4621 #587E21
monochromatic
#080A1D #141A4E #212A7E #2E3AAE #4A57D0

Accessibility & contrast

On white

12.37
#212A7E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.70
#212A7E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #212A7E
12.37:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##212A7E#FFFFFF#000000##FFFFFF
##212A7E1.0012.371.7012.37
#FFFFFF12.371.0021.001.00
#0000001.7021.001.0021.00
##FFFFFF12.371.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003981
Deuteranopia (green-blind)
#00307C
Tritanopia (blue-blind)
#004050
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #212a7e;
/* rgb */ color: rgb(33, 42, 126);
/* oklch */ color: oklch(33.7% 0.141 271.7);
Tailwind
colors: {
  custom: {
    50: '#6b63a4',
    500: '#212a7e',
    950: '#000000',
  },
}
SCSS
$custom: #212a7e;
$custom-light: #6b63a4;
$custom-dark: #000000;
JSON
{
  "hex": "#212a7e",
  "rgb": {
    "r": 33,
    "g": 42,
    "b": 126
  },
  "hsl": {
    "h": 234.194,
    "s": 58.491,
    "l": 31.176
  },
  "oklch": {
    "l": 0.33738,
    "c": 0.1405,
    "h": 271.7
  },
  "luminance": 0.03486
}

Semantic roles & 50–950 ramp

primary
#212A7E
secondary
#B1A74A
accent
#D346E2
background
#F6F5FA
surface
#ECEAF4
border
#C7C6CE
text
#07050F
muted
#7A797F

Preview Lab

Preview with #212A7E

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

Preview Lab → · Contrast checker → · Palette generator →

#212A7E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva