#5B217C#5B217C

#5B217C is a dark, vivid violet. Relative luminance 0.048; OKLCH L 38.1% C 0.150 H 310.3°. Best body text is #FFFFFF at 10.75:1 contrast (WCAG AA passes).

Color values

HEX#5B217C
RGBrgb(91, 33, 124)
HSLhsl(278, 58%, 31%)
HSVhsv(278, 73%, 49%)
CMYKcmyk(26.6%, 73.4%, 0%, 51.4%)
CIE-LABlab(26.06, 42.26, -40.29)
CIE-LCHlch(26.06, 58.39, 316.37°)
OKLaboklab(38.13% 0.0968 -0.114)
OKLCHoklch(38.13% 0.15 310.3)
XYZxyz(8.4956, 4.7673, 19.5375)
Luminance0.0477 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B217C #427C21
analogous
#2D217C #5B217C #7C216F
triadic
#5B217C #7C5B21 #217C5B
tetradic
#5B217C #7C2D21 #427C21 #216F7C
square
#5B217C #7C2D21 #427C21 #216F7C
split-complementary
#5B217C #6F7C21 #217C2D
monochromatic
#14071B #38144C #5B217C #7E2EAC #9E49CF

Accessibility & contrast

On white

10.75
#5B217C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.95
#5B217C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B217C
10.75:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B217C#FFFFFF#000000##FFFFFF
##5B217C1.0010.751.9510.75
#FFFFFF10.751.0021.001.00
#0000001.9521.001.0021.00
##FFFFFF10.751.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003B7F
Deuteranopia (green-blind)
#113F7A
Tritanopia (blue-blind)
#56354C
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #5b217c;
/* rgb */ color: rgb(91, 33, 124);
/* oklch */ color: oklch(38.1% 0.150 310.3);
Tailwind
colors: {
  custom: {
    50: '#8d62a2',
    500: '#5b217c',
    950: '#000000',
  },
}
SCSS
$custom: #5b217c;
$custom-light: #8d62a2;
$custom-dark: #000000;
JSON
{
  "hex": "#5b217c",
  "rgb": {
    "r": 91,
    "g": 33,
    "b": 124
  },
  "hsl": {
    "h": 278.242,
    "s": 57.962,
    "l": 30.784
  },
  "oklch": {
    "l": 0.3813,
    "c": 0.14951,
    "h": 310.3
  },
  "luminance": 0.04767
}

Semantic roles & 50–950 ramp

primary
#5B217C
secondary
#6FAF4A
accent
#E1477F
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0D050F
muted
#7D7A7F

Preview Lab

Preview with #5B217C

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

Preview Lab → · Contrast checker → · Palette generator →

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