#401171#401171

#401171 is a dark, vivid violet. Relative luminance 0.027; OKLCH L 31.8% C 0.149 H 299.6°. Best body text is #FFFFFF at 13.67:1 contrast (WCAG AA passes).

Color values

HEX#401171
RGBrgb(64, 17, 113)
HSLhsl(269, 74%, 25%)
HSVhsv(269, 85%, 44%)
CMYKcmyk(43.4%, 85%, 0%, 55.7%)
CIE-LABlab(18.73, 41.27, -45.35)
CIE-LCHlch(18.73, 61.32, 312.30°)
OKLaboklab(31.83% 0.0738 -0.1298)
OKLCHoklch(31.83% 0.149 299.6)
XYZxyz(5.2947, 2.6831, 15.8585)
Luminance0.0268 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401171 #427111
analogous
#111271 #401171 #701171
triadic
#401171 #714011 #117140
tetradic
#401171 #711112 #427111 #117170
square
#401171 #711112 #427111 #117170
split-complementary
#401171 #717011 #127111
monochromatic
#0F041B #22093C #401171 #5E19A6 #7C21DB

Accessibility & contrast

On white

13.67
#401171 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.54
#401171 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401171
13.67:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401171#FFFFFF#000000##FFFFFF
##4011711.0013.671.5413.67
#FFFFFF13.671.0021.001.00
#0000001.5421.001.0021.00
##FFFFFF13.671.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002D74
Deuteranopia (green-blind)
#002D6F
Tritanopia (blue-blind)
#342C42
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #401171;
/* rgb */ color: rgb(64, 17, 113);
/* oklch */ color: oklch(31.8% 0.149 299.6);
Tailwind
colors: {
  custom: {
    50: '#7b569b',
    500: '#401171',
    950: '#000000',
  },
}
SCSS
$custom: #401171;
$custom-light: #7b569b;
$custom-dark: #000000;
JSON
{
  "hex": "#401171",
  "rgb": {
    "r": 64,
    "g": 17,
    "b": 113
  },
  "hsl": {
    "h": 269.375,
    "s": 73.846,
    "l": 25.49
  },
  "oklch": {
    "l": 0.31834,
    "c": 0.14926,
    "h": 299.6
  },
  "luminance": 0.02683
}

Semantic roles & 50–950 ramp

primary
#401171
secondary
#70A836
accent
#F13796
background
#F7F5F9
surface
#EEE9F2
border
#C9C5CC
text
#0A030E
muted
#7C787E

Preview Lab

Preview with #401171

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

Preview Lab → · Contrast checker → · Palette generator →

#401171 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva