#5B1871#5B1871

#5B1871 is a dark, vivid purple. Relative luminance 0.041; OKLCH L 36.3% C 0.149 H 316.2°. Best body text is #FFFFFF at 11.58:1 contrast (WCAG AA passes).

Color values

HEX#5B1871
RGBrgb(91, 24, 113)
HSLhsl(285, 65%, 27%)
HSVhsv(285, 79%, 44%)
CMYKcmyk(19.5%, 78.8%, 0%, 55.7%)
CIE-LABlab(23.90, 43.62, -36.75)
CIE-LCHlch(23.90, 57.04, 319.88°)
OKLaboklab(36.34% 0.1078 -0.1035)
OKLCHoklch(36.34% 0.149 316.2)
XYZxyz(7.6212, 4.0700, 16.0037)
Luminance0.0407 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B1871 #2E7118
analogous
#2F1871 #5B1871 #71185B
triadic
#5B1871 #715B18 #18715B
tetradic
#5B1871 #712F18 #2E7118 #185B71
square
#5B1871 #712F18 #2E7118 #185B71
split-complementary
#5B1871 #5B7118 #18712F
monochromatic
#140519 #320D3F #5B1871 #8423A3 #AB30D3

Accessibility & contrast

On white

11.58
#5B1871 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.81
#5B1871 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B1871
11.58:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B1871#FFFFFF#000000##FFFFFF
##5B18711.0011.581.8111.58
#FFFFFF11.581.0021.001.00
#0000001.8121.001.0021.00
##FFFFFF11.581.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003573
Deuteranopia (green-blind)
#173B6F
Tritanopia (blue-blind)
#5A2C44
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #5b1871;
/* rgb */ color: rgb(91, 24, 113);
/* oklch */ color: oklch(36.3% 0.149 316.2);
Tailwind
colors: {
  custom: {
    50: '#8d5d9a',
    500: '#5b1871',
    950: '#000000',
  },
}
SCSS
$custom: #5b1871;
$custom-light: #8d5d9a;
$custom-dark: #000000;
JSON
{
  "hex": "#5b1871",
  "rgb": {
    "r": 91,
    "g": 24,
    "b": 113
  },
  "hsl": {
    "h": 285.169,
    "s": 64.964,
    "l": 26.863
  },
  "oklch": {
    "l": 0.36339,
    "c": 0.14948,
    "h": 316.2
  },
  "luminance": 0.0407
}

Semantic roles & 50–950 ramp

primary
#5B1871
secondary
#58A63E
accent
#E84069
background
#F8F5F9
surface
#F0E9F2
border
#CBC5CC
text
#0D050E
muted
#7D797E

Preview Lab

Preview with #5B1871

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

Preview Lab → · Contrast checker → · Palette generator →

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