#401D7E#401D7E

#401D7E is a dark, vivid violet. Relative luminance 0.035; OKLCH L 34.4% C 0.151 H 293.2°. Best body text is #FFFFFF at 12.39:1 contrast (WCAG AA passes).

Color values

HEX#401D7E
RGBrgb(64, 29, 126)
HSLhsl(262, 63%, 30%)
HSVhsv(262, 77%, 49%)
CMYKcmyk(49.2%, 77%, 0%, 50.6%)
CIE-LABlab(21.85, 39.39, -48.56)
CIE-LCHlch(21.85, 62.53, 309.05°)
OKLaboklab(34.4% 0.0596 -0.1393)
OKLCHoklch(34.4% 0.151 293.2)
XYZxyz(6.3186, 3.4749, 20.0724)
Luminance0.0348 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401D7E #5B7E1D
analogous
#1D2B7E #401D7E #701D7E
triadic
#401D7E #7E401D #1D7E40
tetradic
#401D7E #7E1D2B #5B7E1D #1D7E70
square
#401D7E #7E1D2B #5B7E1D #1D7E70
split-complementary
#401D7E #7E701D #2B7E1D
monochromatic
#0D061B #27124C #401D7E #5928B0 #7642D3

Accessibility & contrast

On white

12.39
#401D7E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.70
#401D7E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401D7E
12.39:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401D7E#FFFFFF#000000##FFFFFF
##401D7E1.0012.391.7012.39
#FFFFFF12.391.0021.001.00
#0000001.7021.001.0021.00
##FFFFFF12.391.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003581
Deuteranopia (green-blind)
#00337C
Tritanopia (blue-blind)
#2D374C
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #401d7e;
/* rgb */ color: rgb(64, 29, 126);
/* oklch */ color: oklch(34.4% 0.151 293.2);
Tailwind
colors: {
  custom: {
    50: '#7c5da4',
    500: '#401d7e',
    950: '#000000',
  },
}
SCSS
$custom: #401d7e;
$custom-light: #7c5da4;
$custom-dark: #000000;
JSON
{
  "hex": "#401d7e",
  "rgb": {
    "r": 64,
    "g": 29,
    "b": 126
  },
  "hsl": {
    "h": 261.649,
    "s": 62.581,
    "l": 30.392
  },
  "oklch": {
    "l": 0.34399,
    "c": 0.15149,
    "h": 293.2
  },
  "luminance": 0.03475
}

Semantic roles & 50–950 ramp

primary
#401D7E
secondary
#8AB145
accent
#E642AB
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#0A040F
muted
#7C797F

Preview Lab

Preview with #401D7E

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

Preview Lab → · Contrast checker → · Palette generator →

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