#402DA9#402DA9

#402DA9 is a dark, vivid blue. Relative luminance 0.058; OKLCH L 40.7% C 0.186 H 281.2°. Best body text is #FFFFFF at 9.69:1 contrast (WCAG AA passes).

Color values

HEX#402DA9
RGBrgb(64, 45, 169)
HSLhsl(249, 58%, 42%)
HSVhsv(249, 73%, 66%)
CMYKcmyk(62.1%, 73.4%, 0%, 33.7%)
CIE-LABlab(28.98, 43.81, -63.40)
CIE-LCHlch(28.98, 77.07, 304.65°)
OKLaboklab(40.69% 0.0361 -0.1828)
OKLCHoklch(40.69% 0.186 281.2)
XYZxyz(10.2119, 5.8306, 38.1157)
Luminance0.0583 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402DA9 #96A92D
analogous
#2D58A9 #402DA9 #7E2DA9
triadic
#402DA9 #A9402D #2DA940
tetradic
#402DA9 #A92D58 #96A92D #2DA97E
square
#402DA9 #A92D58 #96A92D #2DA97E
split-complementary
#402DA9 #A97E2D #58A92D
monochromatic
#1B1348 #2E2079 #402DA9 #5A46CE #8576DA

Accessibility & contrast

On white

9.69
#402DA9 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.17
#402DA9 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402DA9
9.69:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402DA9#FFFFFF#000000##FFFFFF
##402DA91.009.692.179.69
#FFFFFF9.691.0021.001.00
#0000002.1721.001.0021.00
##FFFFFF9.691.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0049AD
Deuteranopia (green-blind)
#0040A7
Tritanopia (blue-blind)
#004F68
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #402da9;
/* rgb */ color: rgb(64, 45, 169);
/* oklch */ color: oklch(40.7% 0.186 281.2);
Tailwind
colors: {
  custom: {
    50: '#8268c4',
    500: '#402da9',
    950: '#000000',
  },
}
SCSS
$custom: #402da9;
$custom-light: #8268c4;
$custom-dark: #000000;
JSON
{
  "hex": "#402da9",
  "rgb": {
    "r": 64,
    "g": 45,
    "b": 169
  },
  "hsl": {
    "h": 249.194,
    "s": 57.944,
    "l": 41.961
  },
  "oklch": {
    "l": 0.40687,
    "c": 0.18637,
    "h": 281.2
  },
  "luminance": 0.05831
}

Semantic roles & 50–950 ramp

primary
#402DA9
secondary
#B6C26F
accent
#E147C9
background
#F8F6FC
surface
#F0EBF8
border
#CBC6D1
text
#0C0613
muted
#7D7A82

Preview Lab

Preview with #402DA9

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

Preview Lab → · Contrast checker → · Palette generator →

#402DA9 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva