#402FC2#402FC2

#402FC2 is a dark, highly saturated blue. Relative luminance 0.070; OKLCH L 43.5% C 0.214 H 277.8°. Best body text is #FFFFFF at 8.74:1 contrast (WCAG AA passes).

Color values

HEX#402FC2
RGBrgb(64, 47, 194)
HSLhsl(247, 61%, 47%)
HSVhsv(247, 76%, 76%)
CMYKcmyk(67%, 75.8%, 0%, 23.9%)
CIE-LABlab(31.85, 50.49, -73.54)
CIE-LCHlch(31.85, 89.21, 304.47°)
OKLaboklab(43.46% 0.0292 -0.2124)
OKLCHoklch(43.46% 0.214 277.8)
XYZxyz(12.8653, 7.0170, 51.7049)
Luminance0.0702 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402FC2 #B1C22F
analogous
#2F67C2 #402FC2 #8A2FC2
triadic
#402FC2 #C2402F #2FC240
tetradic
#402FC2 #C22F67 #B1C22F #2FC28A
square
#402FC2 #C22F67 #B1C22F #2FC28A
split-complementary
#402FC2 #C28A2F #67C22F
monochromatic
#1F175F #302391 #402FC2 #6658D6 #9389E2

Accessibility & contrast

On white

8.74
#402FC2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.40
#402FC2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402FC2
8.74:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402FC2#FFFFFF#000000##FFFFFF
##402FC21.008.742.408.74
#FFFFFF8.741.0021.001.00
#0000002.4021.001.0021.00
##FFFFFF8.741.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0051C6
Deuteranopia (green-blind)
#0045BF
Tritanopia (blue-blind)
#005A77
Achromatopsia (no color)
#4B4B4B

Design tokens & code

CSS
--color: #402fc2;
/* rgb */ color: rgb(64, 47, 194);
/* oklch */ color: oklch(43.5% 0.214 277.8);
Tailwind
colors: {
  custom: {
    50: '#876bd6',
    500: '#402fc2',
    950: '#000000',
  },
}
SCSS
$custom: #402fc2;
$custom-light: #876bd6;
$custom-dark: #000000;
JSON
{
  "hex": "#402fc2",
  "rgb": {
    "r": 64,
    "g": 47,
    "b": 194
  },
  "hsl": {
    "h": 246.939,
    "s": 60.996,
    "l": 47.255
  },
  "oklch": {
    "l": 0.43457,
    "c": 0.21444,
    "h": 277.8
  },
  "luminance": 0.07018
}

Semantic roles & 50–950 ramp

primary
#402FC2
secondary
#C3CC81
accent
#E444D2
background
#F9F6FD
surface
#F1EBFA
border
#CBC6D3
text
#0D0714
muted
#7E7A83

Preview Lab

Preview with #402FC2

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

Preview Lab → · Contrast checker → · Palette generator →

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