#21187F#21187F

#21187F is a dark, vivid blue. Relative luminance 0.025; OKLCH L 31.0% C 0.162 H 275.2°. Best body text is #FFFFFF at 13.98:1 contrast (WCAG AA passes).

Color values

HEX#21187F
RGBrgb(33, 24, 127)
HSLhsl(245, 68%, 30%)
HSVhsv(245, 81%, 50%)
CMYKcmyk(74%, 81.1%, 0%, 50.2%)
CIE-LABlab(17.96, 38.24, -55.72)
CIE-LCHlch(17.96, 67.58, 304.46°)
OKLaboklab(30.95% 0.0147 -0.1611)
OKLCHoklch(30.95% 0.162 275.2)
XYZxyz(4.7833, 2.5084, 20.3067)
Luminance0.0251 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#21187F #767F18
analogous
#18427F #21187F #55187F
triadic
#21187F #7F2118 #187F21
tetradic
#21187F #7F1842 #767F18 #187F55
square
#21187F #7F1842 #767F18 #187F55
split-complementary
#21187F #7F5518 #427F18
monochromatic
#07051A #140E4C #21187F #2E22B2 #4638D9

Accessibility & contrast

On white

13.98
#21187F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.50
#21187F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #21187F
13.98:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##21187F#FFFFFF#000000##FFFFFF
##21187F1.0013.981.5013.98
#FFFFFF13.981.0021.001.00
#0000001.5021.001.0021.00
##FFFFFF13.981.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003082
Deuteranopia (green-blind)
#00277D
Tritanopia (blue-blind)
#00374B
Achromatopsia (no color)
#2C2C2C

Design tokens & code

CSS
--color: #21187f;
/* rgb */ color: rgb(33, 24, 127);
/* oklch */ color: oklch(31.0% 0.162 275.2);
Tailwind
colors: {
  custom: {
    50: '#6d58a5',
    500: '#21187f',
    950: '#000000',
  },
}
SCSS
$custom: #21187f;
$custom-light: #6d58a5;
$custom-dark: #000000;
JSON
{
  "hex": "#21187f",
  "rgb": {
    "r": 33,
    "g": 24,
    "b": 127
  },
  "hsl": {
    "h": 245.243,
    "s": 68.212,
    "l": 29.608
  },
  "oklch": {
    "l": 0.30951,
    "c": 0.16179,
    "h": 275.2
  },
  "luminance": 0.02509
}

Semantic roles & 50–950 ramp

primary
#21187F
secondary
#A9B33F
accent
#EB3DDC
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#08030F
muted
#7B787F

Preview Lab

Preview with #21187F

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

Preview Lab → · Contrast checker → · Palette generator →

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