#5B287D#5B287D

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

Color values

HEX#5B287D
RGBrgb(91, 40, 125)
HSLhsl(276, 52%, 32%)
HSVhsv(276, 68%, 49%)
CMYKcmyk(27.2%, 68%, 0%, 51%)
CIE-LABlab(27.36, 39.08, -38.83)
CIE-LCHlch(27.36, 55.09, 315.19°)
OKLaboklab(39.08% 0.0884 -0.1097)
OKLCHoklch(39.08% 0.141 308.9)
XYZxyz(8.7741, 5.2225, 19.9439)
Luminance0.0522 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B287D #4A7D28
analogous
#31287D #5B287D #7D2875
triadic
#5B287D #7D5B28 #287D5B
tetradic
#5B287D #7D3128 #4A7D28 #28757D
square
#5B287D #7D3128 #4A7D28 #28757D
split-complementary
#5B287D #757D28 #287D31
monochromatic
#170A20 #39194F #5B287D #7D37AB #9B56C9

Accessibility & contrast

On white

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

On black

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

Best text color

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

Contrast matrix

fg \ bg##5B287D#FFFFFF#000000##FFFFFF
##5B287D1.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)
#003F80
Deuteranopia (green-blind)
#19417B
Tritanopia (blue-blind)
#563A4F
Achromatopsia (no color)
#414141

Design tokens & code

CSS
--color: #5b287d;
/* rgb */ color: rgb(91, 40, 125);
/* oklch */ color: oklch(39.1% 0.141 308.9);
Tailwind
colors: {
  custom: {
    50: '#8d66a3',
    500: '#5b287d',
    950: '#000000',
  },
}
SCSS
$custom: #5b287d;
$custom-light: #8d66a3;
$custom-dark: #000000;
JSON
{
  "hex": "#5b287d",
  "rgb": {
    "r": 91,
    "g": 40,
    "b": 125
  },
  "hsl": {
    "h": 276,
    "s": 51.515,
    "l": 32.353
  },
  "oklch": {
    "l": 0.39083,
    "c": 0.14093,
    "h": 308.9
  },
  "luminance": 0.05222
}

Semantic roles & 50–950 ramp

primary
#5B287D
secondary
#77AE53
accent
#DB4D86
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0C060F
muted
#7D7A7F

Preview Lab

Preview with #5B287D

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

Preview Lab → · Contrast checker → · Palette generator →

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