#401C7F#401C7F

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

Color values

HEX#401C7F
RGBrgb(64, 28, 127)
HSLhsl(262, 64%, 30%)
HSVhsv(262, 78%, 50%)
CMYKcmyk(49.6%, 78%, 0%, 50.2%)
CIE-LABlab(21.77, 40.17, -49.33)
CIE-LCHlch(21.77, 63.62, 309.16°)
OKLaboklab(34.37% 0.0602 -0.1415)
OKLCHoklch(34.37% 0.154 293)
XYZxyz(6.3593, 3.4526, 20.4059)
Luminance0.0345 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401C7F #5B7F1C
analogous
#1C2A7F #401C7F #711C7F
triadic
#401C7F #7F401C #1C7F40
tetradic
#401C7F #7F1C2A #5B7F1C #1C7F71
square
#401C7F #7F1C2A #5B7F1C #1C7F71
split-complementary
#401C7F #7F711C #2A7F1C
monochromatic
#0D061B #27114D #401C7F #5927B1 #7640D5

Accessibility & contrast

On white

12.42
#401C7F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.69
#401C7F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401C7F
12.42:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401C7F#FFFFFF#000000##FFFFFF
##401C7F1.0012.421.6912.42
#FFFFFF12.421.0021.001.00
#0000001.6921.001.0021.00
##FFFFFF12.421.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003582
Deuteranopia (green-blind)
#00327D
Tritanopia (blue-blind)
#2C374C
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #401c7f;
/* rgb */ color: rgb(64, 28, 127);
/* oklch */ color: oklch(34.4% 0.154 293.0);
Tailwind
colors: {
  custom: {
    50: '#7c5ca5',
    500: '#401c7f',
    950: '#000000',
  },
}
SCSS
$custom: #401c7f;
$custom-light: #7c5ca5;
$custom-dark: #000000;
JSON
{
  "hex": "#401c7f",
  "rgb": {
    "r": 64,
    "g": 28,
    "b": 127
  },
  "hsl": {
    "h": 261.818,
    "s": 63.871,
    "l": 30.392
  },
  "oklch": {
    "l": 0.34371,
    "c": 0.15379,
    "h": 293
  },
  "luminance": 0.03453
}

Semantic roles & 50–950 ramp

primary
#401C7F
secondary
#8AB344
accent
#E741AB
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#0A040F
muted
#7C797F

Preview Lab

Preview with #401C7F

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

Preview Lab → · Contrast checker → · Palette generator →

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