#21227D#21227D

#21227D is a dark, vivid blue. Relative luminance 0.029; OKLCH L 32.2% C 0.149 H 273.7°. Best body text is #FFFFFF at 13.21:1 contrast (WCAG AA passes).

Color values

HEX#21227D
RGBrgb(33, 34, 125)
HSLhsl(239, 58%, 31%)
HSVhsv(239, 74%, 49%)
CMYKcmyk(73.6%, 72.8%, 0%, 51%)
CIE-LABlab(19.83, 31.63, -51.35)
CIE-LCHlch(19.83, 60.32, 301.63°)
OKLaboklab(32.21% 0.0097 -0.1485)
OKLCHoklch(32.21% 0.149 273.7)
XYZxyz(4.8997, 2.9476, 19.7088)
Luminance0.0295 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#21227D #7D7C21
analogous
#21507D #21227D #4E217D
triadic
#21227D #7D2122 #227D21
tetradic
#21227D #7D2150 #7D7C21 #217D4E
square
#21227D #7D2150 #7D7C21 #217D4E
split-complementary
#21227D #7D4E21 #507D21
monochromatic
#07081C #14154D #21227D #2E2FAD #494BCF

Accessibility & contrast

On white

13.21
#21227D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.59
#21227D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #21227D
13.21:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##21227D#FFFFFF#000000##FFFFFF
##21227D1.0013.211.5913.21
#FFFFFF13.211.0021.001.00
#0000001.5921.001.0021.00
##FFFFFF13.211.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003480
Deuteranopia (green-blind)
#002C7B
Tritanopia (blue-blind)
#003B4D
Achromatopsia (no color)
#303030

Design tokens & code

CSS
--color: #21227d;
/* rgb */ color: rgb(33, 34, 125);
/* oklch */ color: oklch(32.2% 0.149 273.7);
Tailwind
colors: {
  custom: {
    50: '#6b5ea4',
    500: '#21227d',
    950: '#000000',
  },
}
SCSS
$custom: #21227d;
$custom-light: #6b5ea4;
$custom-dark: #000000;
JSON
{
  "hex": "#21227d",
  "rgb": {
    "r": 33,
    "g": 34,
    "b": 125
  },
  "hsl": {
    "h": 239.348,
    "s": 58.228,
    "l": 30.98
  },
  "oklch": {
    "l": 0.32215,
    "c": 0.1488,
    "h": 273.7
  },
  "luminance": 0.02948
}

Semantic roles & 50–950 ramp

primary
#21227D
secondary
#B0AF4A
accent
#E046E1
background
#F6F5FA
surface
#ECE9F4
border
#C7C5CE
text
#08040F
muted
#7A797F

Preview Lab

Preview with #21227D

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

Preview Lab → · Contrast checker → · Palette generator →

#21227D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva