#5B1171#5B1171

#5B1171 is a dark, vivid purple. Relative luminance 0.038; OKLCH L 35.7% C 0.157 H 316.7°. Best body text is #FFFFFF at 11.91:1 contrast (WCAG AA passes).

Color values

HEX#5B1171
RGBrgb(91, 17, 113)
HSLhsl(286, 74%, 25%)
HSVhsv(286, 85%, 44%)
CMYKcmyk(19.5%, 85%, 0%, 55.7%)
CIE-LABlab(23.06, 46.05, -38.11)
CIE-LCHlch(23.06, 59.78, 320.39°)
OKLaboklab(35.74% 0.114 -0.1075)
OKLCHoklch(35.74% 0.157 316.7)
XYZxyz(7.4950, 3.8176, 15.9617)
Luminance0.0382 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B1171 #277111
analogous
#2B1171 #5B1171 #711157
triadic
#5B1171 #715B11 #11715B
tetradic
#5B1171 #712B11 #277111 #115771
square
#5B1171 #712B11 #277111 #115771
split-complementary
#5B1171 #577111 #11712B
monochromatic
#15041B #30093C #5B1171 #8619A6 #B121DB

Accessibility & contrast

On white

11.91
#5B1171 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.76
#5B1171 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B1171
11.91:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B1171#FFFFFF#000000##FFFFFF
##5B11711.0011.911.7611.91
#FFFFFF11.911.0021.001.00
#0000001.7621.001.0021.00
##FFFFFF11.911.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003374
Deuteranopia (green-blind)
#11396F
Tritanopia (blue-blind)
#5A2842
Achromatopsia (no color)
#373737

Design tokens & code

CSS
--color: #5b1171;
/* rgb */ color: rgb(91, 17, 113);
/* oklch */ color: oklch(35.7% 0.157 316.7);
Tailwind
colors: {
  custom: {
    50: '#8d5a9a',
    500: '#5b1171',
    950: '#000000',
  },
}
SCSS
$custom: #5b1171;
$custom-light: #8d5a9a;
$custom-dark: #000000;
JSON
{
  "hex": "#5b1171",
  "rgb": {
    "r": 91,
    "g": 17,
    "b": 113
  },
  "hsl": {
    "h": 286.25,
    "s": 73.846,
    "l": 25.49
  },
  "oklch": {
    "l": 0.35745,
    "c": 0.15668,
    "h": 316.7
  },
  "luminance": 0.03817
}

Semantic roles & 50–950 ramp

primary
#5B1171
secondary
#50A836
accent
#F13762
background
#F9F5F9
surface
#F1E9F2
border
#CBC5CC
text
#0D040E
muted
#7E797E

Preview Lab

Preview with #5B1171

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

Preview Lab → · Contrast checker → · Palette generator →

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