#5B217E#5B217E

#5B217E is a dark, vivid violet. Relative luminance 0.048; OKLCH L 38.3% C 0.152 H 309.5°. Best body text is #FFFFFF at 10.69:1 contrast (WCAG AA passes).

Color values

HEX#5B217E
RGBrgb(91, 33, 126)
HSLhsl(277, 58%, 31%)
HSVhsv(277, 74%, 49%)
CMYKcmyk(27.8%, 73.8%, 0%, 50.6%)
CIE-LABlab(26.21, 42.73, -41.31)
CIE-LCHlch(26.21, 59.43, 315.97°)
OKLaboklab(38.28% 0.0965 -0.117)
OKLCHoklch(38.28% 0.152 309.5)
XYZxyz(8.6234, 4.8184, 20.2104)
Luminance0.0482 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B217E #447E21
analogous
#2C217E #5B217E #7E2172
triadic
#5B217E #7E5B21 #217E5B
tetradic
#5B217E #7E2C21 #447E21 #21727E
square
#5B217E #7E2C21 #447E21 #21727E
split-complementary
#5B217E #727E21 #217E2C
monochromatic
#15081D #38144E #5B217E #7E2EAE #9D4AD0

Accessibility & contrast

On white

10.69
#5B217E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.96
#5B217E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B217E
10.69:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B217E#FFFFFF#000000##FFFFFF
##5B217E1.0010.691.9610.69
#FFFFFF10.691.0021.001.00
#0000001.9621.001.0021.00
##FFFFFF10.691.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003C81
Deuteranopia (green-blind)
#0D3F7C
Tritanopia (blue-blind)
#56364D
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #5b217e;
/* rgb */ color: rgb(91, 33, 126);
/* oklch */ color: oklch(38.3% 0.152 309.5);
Tailwind
colors: {
  custom: {
    50: '#8d62a4',
    500: '#5b217e',
    950: '#000000',
  },
}
SCSS
$custom: #5b217e;
$custom-light: #8d62a4;
$custom-dark: #000000;
JSON
{
  "hex": "#5b217e",
  "rgb": {
    "r": 91,
    "g": 33,
    "b": 126
  },
  "hsl": {
    "h": 277.419,
    "s": 58.491,
    "l": 31.176
  },
  "oklch": {
    "l": 0.38284,
    "c": 0.15164,
    "h": 309.5
  },
  "luminance": 0.04818
}

Semantic roles & 50–950 ramp

primary
#5B217E
secondary
#71B14A
accent
#E24681
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0D050F
muted
#7D7A7F

Preview Lab

Preview with #5B217E

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

Preview Lab → · Contrast checker → · Palette generator →

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