#21127E#21127E

#21127E is a dark, vivid blue. Relative luminance 0.023; OKLCH L 30.1% C 0.166 H 276.1°. Best body text is #FFFFFF at 14.46:1 contrast (WCAG AA passes).

Color values

HEX#21127E
RGBrgb(33, 18, 126)
HSLhsl(248, 75%, 28%)
HSVhsv(248, 86%, 49%)
CMYKcmyk(73.8%, 85.7%, 0%, 50.6%)
CIE-LABlab(16.81, 40.92, -56.99)
CIE-LCHlch(16.81, 70.16, 305.68°)
OKLaboklab(30.12% 0.0175 -0.1647)
OKLCHoklch(30.12% 0.166 276.1)
XYZxyz(4.6082, 2.2619, 19.9283)
Luminance0.0226 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#21127E #6F7E12
analogous
#12397E #21127E #57127E
triadic
#21127E #7E2112 #127E21
tetradic
#21127E #7E1239 #6F7E12 #127E57
square
#21127E #7E1239 #6F7E12 #127E57
split-complementary
#21127E #7E5712 #397E12
monochromatic
#07041B #130A48 #21127E #2F1AB4 #432AE1

Accessibility & contrast

On white

14.46
#21127E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.45
#21127E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #21127E
14.46:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##21127E#FFFFFF#000000##FFFFFF
##21127E1.0014.461.4514.46
#FFFFFF14.461.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.461.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E81
Deuteranopia (green-blind)
#00257C
Tritanopia (blue-blind)
#00354A
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #21127e;
/* rgb */ color: rgb(33, 18, 126);
/* oklch */ color: oklch(30.1% 0.166 276.1);
Tailwind
colors: {
  custom: {
    50: '#6d54a5',
    500: '#21127e',
    950: '#000000',
  },
}
SCSS
$custom: #21127e;
$custom-light: #6d54a5;
$custom-dark: #000000;
JSON
{
  "hex": "#21127e",
  "rgb": {
    "r": 33,
    "g": 18,
    "b": 126
  },
  "hsl": {
    "h": 248.333,
    "s": 75,
    "l": 28.235
  },
  "oklch": {
    "l": 0.30117,
    "c": 0.16564,
    "h": 276.1
  },
  "luminance": 0.02262
}

Semantic roles & 50–950 ramp

primary
#21127E
secondary
#A3B438
accent
#F236D8
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#08030F
muted
#7B787F

Preview Lab

Preview with #21127E

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

Preview Lab → · Contrast checker → · Palette generator →

#21127E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva