#5E31A1#5E31A1

#5E31A1 is a dark, vivid violet. Relative luminance 0.071; OKLCH L 43.5% C 0.171 H 297.1°. Best body text is #FFFFFF at 8.64:1 contrast (WCAG AA passes).

Color values

HEX#5E31A1
RGBrgb(94, 49, 161)
HSLhsl(264, 53%, 41%)
HSVhsv(264, 70%, 63%)
CMYKcmyk(41.6%, 69.6%, 0%, 36.9%)
CIE-LABlab(32.14, 44.33, -53.28)
CIE-LCHlch(32.14, 69.30, 309.76°)
OKLaboklab(43.45% 0.0779 -0.1521)
OKLCHoklch(43.45% 0.171 297.1)
XYZxyz(12.1458, 7.1493, 34.4513)
Luminance0.0715 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5E31A1 #74A131
analogous
#313CA1 #5E31A1 #9631A1
triadic
#5E31A1 #A15E31 #31A15E
tetradic
#5E31A1 #A1313C #74A131 #31A196
square
#5E31A1 #A1313C #74A131 #31A196
split-complementary
#5E31A1 #A19631 #3CA131
monochromatic
#271443 #432372 #5E31A1 #7B48C7 #9D77D6

Accessibility & contrast

On white

8.64
#5E31A1 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.43
#5E31A1 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5E31A1
8.64:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5E31A1#FFFFFF#000000##FFFFFF
##5E31A11.008.642.438.64
#FFFFFF8.641.0021.001.00
#0000002.4321.001.0021.00
##FFFFFF8.641.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CA4
Deuteranopia (green-blind)
#004A9F
Tritanopia (blue-blind)
#4D4C65
Achromatopsia (no color)
#4C4C4C

Design tokens & code

CSS
--color: #5e31a1;
/* rgb */ color: rgb(94, 49, 161);
/* oklch */ color: oklch(43.5% 0.171 297.1);
Tailwind
colors: {
  custom: {
    50: '#916dbe',
    500: '#5e31a1',
    950: '#000000',
  },
}
SCSS
$custom: #5e31a1;
$custom-light: #916dbe;
$custom-dark: #000000;
JSON
{
  "hex": "#5e31a1",
  "rgb": {
    "r": 94,
    "g": 49,
    "b": 161
  },
  "hsl": {
    "h": 264.107,
    "s": 53.333,
    "l": 41.176
  },
  "oklch": {
    "l": 0.43454,
    "c": 0.17093,
    "h": 297.1
  },
  "luminance": 0.0715
}

Semantic roles & 50–950 ramp

primary
#5E31A1
secondary
#9FBE70
accent
#DD4BA2
background
#F9F6FB
surface
#F2ECF7
border
#CCC7D0
text
#0D0712
muted
#7E7A81

Preview Lab

Preview with #5E31A1

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

Preview Lab → · Contrast checker → · Palette generator →

#5E31A1 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva