#5E1F8B#5E1F8B

#5E1F8B is a dark, vivid violet. Relative luminance 0.052; OKLCH L 39.5% C 0.168 H 306.6°. Best body text is #FFFFFF at 10.27:1 contrast (WCAG AA passes).

Color values

HEX#5E1F8B
RGBrgb(94, 31, 139)
HSLhsl(275, 64%, 33%)
HSVhsv(275, 78%, 55%)
CMYKcmyk(32.4%, 77.7%, 0%, 45.5%)
CIE-LABlab(27.36, 47.27, -47.57)
CIE-LCHlch(27.36, 67.06, 314.82°)
OKLaboklab(39.51% 0.1003 -0.1353)
OKLCHoklch(39.51% 0.168 306.6)
XYZxyz(9.7653, 5.2238, 24.9149)
Luminance0.0522 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5E1F8B #4C8B1F
analogous
#281F8B #5E1F8B #8B1F82
triadic
#5E1F8B #8B5E1F #1F8B5E
tetradic
#5E1F8B #8B281F #4C8B1F #1F828B
square
#5E1F8B #8B281F #4C8B1F #1F828B
split-complementary
#5E1F8B #828B1F #1F8B28
monochromatic
#1A0927 #3C1459 #5E1F8B #802ABD #9E4DD7

Accessibility & contrast

On white

10.27
#5E1F8B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.04
#5E1F8B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5E1F8B
10.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5E1F8B#FFFFFF#000000##FFFFFF
##5E1F8B1.0010.272.0410.27
#FFFFFF10.271.0021.001.00
#0000002.0421.001.0021.00
##FFFFFF10.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003F8E
Deuteranopia (green-blind)
#004189
Tritanopia (blue-blind)
#563A54
Achromatopsia (no color)
#414141

Design tokens & code

CSS
--color: #5e1f8b;
/* rgb */ color: rgb(94, 31, 139);
/* oklch */ color: oklch(39.5% 0.168 306.6);
Tailwind
colors: {
  custom: {
    50: '#9062ae',
    500: '#5e1f8b',
    950: '#000000',
  },
}
SCSS
$custom: #5e1f8b;
$custom-light: #9062ae;
$custom-dark: #000000;
JSON
{
  "hex": "#5e1f8b",
  "rgb": {
    "r": 94,
    "g": 31,
    "b": 139
  },
  "hsl": {
    "h": 275,
    "s": 63.529,
    "l": 33.333
  },
  "oklch": {
    "l": 0.39512,
    "c": 0.16841,
    "h": 306.6
  },
  "luminance": 0.05224
}

Semantic roles & 50–950 ramp

primary
#5E1F8B
secondary
#7ABA4C
accent
#E74186
background
#F9F6FA
surface
#F1EBF4
border
#CBC6CE
text
#0D0510
muted
#7E7A7F

Preview Lab

Preview with #5E1F8B

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

Preview Lab → · Contrast checker → · Palette generator →

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