#401F9F#401F9F

#401F9F is a dark, vivid violet. Relative luminance 0.046; OKLCH L 37.9% C 0.188 H 284.8°. Best body text is #FFFFFF at 10.97:1 contrast (WCAG AA passes).

Color values

HEX#401F9F
RGBrgb(64, 31, 159)
HSLhsl(255, 67%, 37%)
HSVhsv(255, 81%, 62%)
CMYKcmyk(59.7%, 80.5%, 0%, 37.6%)
CIE-LABlab(25.48, 47.92, -63.11)
CIE-LCHlch(25.48, 79.24, 307.21°)
OKLaboklab(37.93% 0.0482 -0.1819)
OKLCHoklch(37.93% 0.188 284.8)
XYZxyz(8.8604, 4.5726, 33.2099)
Luminance0.0457 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401F9F #7E9F1F
analogous
#1F3E9F #401F9F #801F9F
triadic
#401F9F #9F401F #1F9F40
tetradic
#401F9F #9F1F3E #7E9F1F #1F9F80
square
#401F9F #9F1F3E #7E9F1F #1F9F80
split-complementary
#401F9F #9F801F #3E9F1F
monochromatic
#170B39 #2B156C #401F9F #5529D2 #7C5ADF

Accessibility & contrast

On white

10.97
#401F9F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.91
#401F9F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401F9F
10.97:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401F9F#FFFFFF#000000##FFFFFF
##401F9F1.0010.971.9110.97
#FFFFFF10.971.0021.001.00
#0000001.9121.001.0021.00
##FFFFFF10.971.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0040A3
Deuteranopia (green-blind)
#00389D
Tritanopia (blue-blind)
#04455F
Achromatopsia (no color)
#3C3C3C

Design tokens & code

CSS
--color: #401f9f;
/* rgb */ color: rgb(64, 31, 159);
/* oklch */ color: oklch(37.9% 0.188 284.8);
Tailwind
colors: {
  custom: {
    50: '#8160bd',
    500: '#401f9f',
    950: '#000000',
  },
}
SCSS
$custom: #401f9f;
$custom-light: #8160bd;
$custom-dark: #000000;
JSON
{
  "hex": "#401f9f",
  "rgb": {
    "r": 64,
    "g": 31,
    "b": 159
  },
  "hsl": {
    "h": 255.469,
    "s": 67.368,
    "l": 37.255
  },
  "oklch": {
    "l": 0.37928,
    "c": 0.18814,
    "h": 284.8
  },
  "luminance": 0.04573
}

Semantic roles & 50–950 ramp

primary
#401F9F
secondary
#A7C357
accent
#EA3EBE
background
#F8F5FB
surface
#F0EAF7
border
#CBC6D0
text
#0C0512
muted
#7D7981

Preview Lab

Preview with #401F9F

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

Preview Lab → · Contrast checker → · Palette generator →

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