#401D8F#401D8F

#401D8F is a dark, vivid violet. Relative luminance 0.040; OKLCH L 36.1% C 0.171 H 288.6°. Best body text is #FFFFFF at 11.73:1 contrast (WCAG AA passes).

Color values

HEX#401D8F
RGBrgb(64, 29, 143)
HSLhsl(258, 66%, 34%)
HSVhsv(258, 80%, 56%)
CMYKcmyk(55.2%, 79.7%, 0%, 43.9%)
CIE-LABlab(23.51, 44.25, -56.51)
CIE-LCHlch(23.51, 71.78, 308.06°)
OKLaboklab(36.06% 0.0546 -0.1626)
OKLCHoklch(36.06% 0.171 288.6)
XYZxyz(7.5102, 3.9515, 26.3483)
Luminance0.0395 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401D8F #6C8F1D
analogous
#1D338F #401D8F #791D8F
triadic
#401D8F #8F401D #1D8F40
tetradic
#401D8F #8F1D33 #6C8F1D #1D8F79
square
#401D8F #8F1D33 #6C8F1D #1D8F79
split-complementary
#401D8F #8F791D #338F1D
monochromatic
#120829 #29135C #401D8F #5727C2 #784CDB

Accessibility & contrast

On white

11.73
#401D8F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.79
#401D8F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401D8F
11.73:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401D8F#FFFFFF#000000##FFFFFF
##401D8F1.0011.731.7911.73
#FFFFFF11.731.0021.001.00
#0000001.7921.001.0021.00
##FFFFFF11.731.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A92
Deuteranopia (green-blind)
#00358D
Tritanopia (blue-blind)
#203E56
Achromatopsia (no color)
#383838

Design tokens & code

CSS
--color: #401d8f;
/* rgb */ color: rgb(64, 29, 143);
/* oklch */ color: oklch(36.1% 0.171 288.6);
Tailwind
colors: {
  custom: {
    50: '#7e5eb1',
    500: '#401d8f',
    950: '#000000',
  },
}
SCSS
$custom: #401d8f;
$custom-light: #7e5eb1;
$custom-dark: #000000;
JSON
{
  "hex": "#401d8f",
  "rgb": {
    "r": 64,
    "g": 29,
    "b": 143
  },
  "hsl": {
    "h": 258.421,
    "s": 66.279,
    "l": 33.725
  },
  "oklch": {
    "l": 0.36064,
    "c": 0.17149,
    "h": 288.6
  },
  "luminance": 0.03952
}

Semantic roles & 50–950 ramp

primary
#401D8F
secondary
#9ABD4B
accent
#E93FB5
background
#F8F5FB
surface
#EFE9F6
border
#CAC5D0
text
#0B0511
muted
#7C7980

Preview Lab

Preview with #401D8F

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

Preview Lab → · Contrast checker → · Palette generator →

#401D8F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva