#401F71#401F71

#401F71 is a dark, vivid violet. Relative luminance 0.033; OKLCH L 33.5% C 0.133 H 297.0°. Best body text is #FFFFFF at 12.71:1 contrast (WCAG AA passes).

Color values

HEX#401F71
RGBrgb(64, 31, 113)
HSLhsl(264, 57%, 28%)
HSVhsv(264, 73%, 44%)
CMYKcmyk(43.4%, 72.6%, 0%, 55.7%)
CIE-LABlab(21.06, 34.62, -41.54)
CIE-LCHlch(21.06, 54.07, 309.81°)
OKLaboklab(33.48% 0.0605 -0.1187)
OKLCHoklch(33.48% 0.133 297)
XYZxyz(5.5842, 3.2621, 15.9550)
Luminance0.0326 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401F71 #50711F
analogous
#1F2771 #401F71 #691F71
triadic
#401F71 #71401F #1F7140
tetradic
#401F71 #711F27 #50711F #1F7169
square
#401F71 #711F27 #50711F #1F7169
split-complementary
#401F71 #71691F #27711F
monochromatic
#0E0718 #251241 #401F71 #5B2CA1 #7840CB

Accessibility & contrast

On white

12.71
#401F71 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.65
#401F71 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401F71
12.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401F71#FFFFFF#000000##FFFFFF
##401F711.0012.711.6512.71
#FFFFFF12.711.0021.001.00
#0000001.6521.001.0021.00
##FFFFFF12.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003373
Deuteranopia (green-blind)
#00326F
Tritanopia (blue-blind)
#343345
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #401f71;
/* rgb */ color: rgb(64, 31, 113);
/* oklch */ color: oklch(33.5% 0.133 297.0);
Tailwind
colors: {
  custom: {
    50: '#7a5d9a',
    500: '#401f71',
    950: '#000000',
  },
}
SCSS
$custom: #401f71;
$custom-light: #7a5d9a;
$custom-dark: #000000;
JSON
{
  "hex": "#401f71",
  "rgb": {
    "r": 64,
    "g": 31,
    "b": 113
  },
  "hsl": {
    "h": 264.146,
    "s": 56.944,
    "l": 28.235
  },
  "oklch": {
    "l": 0.33479,
    "c": 0.13319,
    "h": 297
  },
  "luminance": 0.03262
}

Semantic roles & 50–950 ramp

primary
#401F71
secondary
#7FA547
accent
#E048A3
background
#F7F5F9
surface
#EEE9F2
border
#C9C5CC
text
#0A040E
muted
#7C797E

Preview Lab

Preview with #401F71

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

Preview Lab → · Contrast checker → · Palette generator →

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