#401A7F#401A7F

#401A7F is a dark, vivid violet. Relative luminance 0.034; OKLCH L 34.1% C 0.156 H 293.4°. Best body text is #FFFFFF at 12.56:1 contrast (WCAG AA passes).

Color values

HEX#401A7F
RGBrgb(64, 26, 127)
HSLhsl(263, 66%, 30%)
HSVhsv(263, 80%, 50%)
CMYKcmyk(49.6%, 79.5%, 0%, 50.2%)
CIE-LABlab(21.43, 41.14, -49.88)
CIE-LCHlch(21.43, 64.66, 309.51°)
OKLaboklab(34.13% 0.0619 -0.1431)
OKLCHoklch(34.13% 0.156 293.4)
XYZxyz(6.3135, 3.3609, 20.3906)
Luminance0.0336 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#401A7F #597F1A
analogous
#1A277F #401A7F #721A7F
triadic
#401A7F #7F401A #1A7F40
tetradic
#401A7F #7F1A27 #597F1A #1A7F72
square
#401A7F #7F1A27 #597F1A #1A7F72
split-complementary
#401A7F #7F721A #277F1A
monochromatic
#0D0519 #26104C #401A7F #5A24B2 #773CD7

Accessibility & contrast

On white

12.56
#401A7F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.67
#401A7F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #401A7F
12.56:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##401A7F#FFFFFF#000000##FFFFFF
##401A7F1.0012.561.6712.56
#FFFFFF12.561.0021.001.00
#0000001.6721.001.0021.00
##FFFFFF12.561.0021.001.00

Color blindness preview

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

Design tokens & code

CSS
--color: #401a7f;
/* rgb */ color: rgb(64, 26, 127);
/* oklch */ color: oklch(34.1% 0.156 293.4);
Tailwind
colors: {
  custom: {
    50: '#7c5ba5',
    500: '#401a7f',
    950: '#000000',
  },
}
SCSS
$custom: #401a7f;
$custom-light: #7c5ba5;
$custom-dark: #000000;
JSON
{
  "hex": "#401a7f",
  "rgb": {
    "r": 64,
    "g": 26,
    "b": 127
  },
  "hsl": {
    "h": 262.574,
    "s": 66.013,
    "l": 30
  },
  "oklch": {
    "l": 0.34134,
    "c": 0.15595,
    "h": 293.4
  },
  "luminance": 0.03361
}

Semantic roles & 50–950 ramp

primary
#401A7F
secondary
#88B342
accent
#E93FA9
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#0A040F
muted
#7C797F

Preview Lab

Preview with #401A7F

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

Preview Lab → · Contrast checker → · Palette generator →

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