#402CB2#402CB2

#402CB2 is a dark, vivid blue. Relative luminance 0.061; OKLCH L 41.4% C 0.198 H 280.1°. Best body text is #FFFFFF at 9.45:1 contrast (WCAG AA passes).

Color values

HEX#402CB2
RGBrgb(64, 44, 178)
HSLhsl(249, 60%, 44%)
HSVhsv(249, 75%, 70%)
CMYKcmyk(64%, 75.3%, 0%, 30.2%)
CIE-LABlab(29.68, 47.14, -67.65)
CIE-LCHlch(29.68, 82.46, 304.87°)
OKLaboklab(41.45% 0.0347 -0.1952)
OKLCHoklch(41.45% 0.198 280.1)
XYZxyz(11.0484, 6.1048, 42.7070)
Luminance0.0611 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402CB2 #9EB22C
analogous
#2C5BB2 #402CB2 #832CB2
triadic
#402CB2 #B2402C #2CB240
tetradic
#402CB2 #B22C5B #9EB22C #2CB283
square
#402CB2 #B22C5B #9EB22C #2CB283
split-complementary
#402CB2 #B2832C #5BB22C
monochromatic
#1D1450 #2E2081 #402CB2 #5E49D2 #897ADE

Accessibility & contrast

On white

9.45
#402CB2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.22
#402CB2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402CB2
9.45:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402CB2#FFFFFF#000000##FFFFFF
##402CB21.009.452.229.45
#FFFFFF9.451.0021.001.00
#0000002.2221.001.0021.00
##FFFFFF9.451.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004BB6
Deuteranopia (green-blind)
#0041B0
Tritanopia (blue-blind)
#00526D
Achromatopsia (no color)
#464646

Design tokens & code

CSS
--color: #402cb2;
/* rgb */ color: rgb(64, 44, 178);
/* oklch */ color: oklch(41.4% 0.198 280.1);
Tailwind
colors: {
  custom: {
    50: '#8468ca',
    500: '#402cb2',
    950: '#000000',
  },
}
SCSS
$custom: #402cb2;
$custom-light: #8468ca;
$custom-dark: #000000;
JSON
{
  "hex": "#402cb2",
  "rgb": {
    "r": 64,
    "g": 44,
    "b": 178
  },
  "hsl": {
    "h": 248.955,
    "s": 60.36,
    "l": 43.529
  },
  "oklch": {
    "l": 0.41445,
    "c": 0.1983,
    "h": 280.1
  },
  "luminance": 0.06106
}

Semantic roles & 50–950 ramp

primary
#402CB2
secondary
#BAC673
accent
#E444CC
background
#F8F6FC
surface
#F0EBF9
border
#CBC6D2
text
#0C0613
muted
#7D7A82

Preview Lab

Preview with #402CB2

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

Preview Lab → · Contrast checker → · Palette generator →

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