#21157F#21157F

#21157F is a dark, vivid blue. Relative luminance 0.024; OKLCH L 30.6% C 0.164 H 275.6°. Best body text is #FFFFFF at 14.20:1 contrast (WCAG AA passes).

Color values

HEX#21157F
RGBrgb(33, 21, 127)
HSLhsl(247, 72%, 29%)
HSVhsv(247, 83%, 50%)
CMYKcmyk(74%, 83.5%, 0%, 50.2%)
CIE-LABlab(17.42, 39.79, -56.61)
CIE-LCHlch(17.42, 69.20, 305.10°)
OKLaboklab(30.58% 0.016 -0.1637)
OKLCHoklch(30.58% 0.164 275.6)
XYZxyz(4.7249, 2.3915, 20.2872)
Luminance0.0239 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#21157F #737F15
analogous
#153E7F #21157F #56157F
triadic
#21157F #7F2115 #157F21
tetradic
#21157F #7F153E #737F15 #157F56
square
#21157F #7F153E #737F15 #157F56
split-complementary
#21157F #7F5615 #3E7F15
monochromatic
#07041A #130C4A #21157F #2F1EB4 #4531DD

Accessibility & contrast

On white

14.20
#21157F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.48
#21157F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #21157F
14.20:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##21157F#FFFFFF#000000##FFFFFF
##21157F1.0014.201.4814.20
#FFFFFF14.201.0021.001.00
#0000001.4821.001.0021.00
##FFFFFF14.201.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002F82
Deuteranopia (green-blind)
#00267D
Tritanopia (blue-blind)
#00364B
Achromatopsia (no color)
#2B2B2B

Design tokens & code

CSS
--color: #21157f;
/* rgb */ color: rgb(33, 21, 127);
/* oklch */ color: oklch(30.6% 0.164 275.6);
Tailwind
colors: {
  custom: {
    50: '#6d56a5',
    500: '#21157f',
    950: '#000000',
  },
}
SCSS
$custom: #21157f;
$custom-light: #6d56a5;
$custom-dark: #000000;
JSON
{
  "hex": "#21157f",
  "rgb": {
    "r": 33,
    "g": 21,
    "b": 127
  },
  "hsl": {
    "h": 246.792,
    "s": 71.622,
    "l": 29.02
  },
  "oklch": {
    "l": 0.30578,
    "c": 0.16444,
    "h": 275.6
  },
  "luminance": 0.02392
}

Semantic roles & 50–950 ramp

primary
#21157F
secondary
#A6B43C
accent
#EE39DA
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#08030F
muted
#7B787F

Preview Lab

Preview with #21157F

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

Preview Lab → · Contrast checker → · Palette generator →

#21157F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva