#5B1F95#5B1F95

#5B1F95 is a dark, vivid violet. Relative luminance 0.054; OKLCH L 40.0% C 0.178 H 301.6°. Best body text is #FFFFFF at 10.12:1 contrast (WCAG AA passes).

Color values

HEX#5B1F95
RGBrgb(91, 31, 149)
HSLhsl(271, 66%, 35%)
HSVhsv(271, 79%, 58%)
CMYKcmyk(38.9%, 79.2%, 0%, 41.6%)
CIE-LABlab(27.77, 49.14, -53.10)
CIE-LCHlch(27.77, 72.35, 312.78°)
OKLaboklab(39.97% 0.0934 -0.1516)
OKLCHoklch(39.97% 0.178 301.6)
XYZxyz(10.2279, 5.3740, 28.9264)
Luminance0.0537 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B1F95 #59951F
analogous
#201F95 #5B1F95 #951F94
triadic
#5B1F95 #955B1F #1F955B
tetradic
#5B1F95 #95201F #59951F #1F9495
square
#5B1F95 #95201F #59951F #1F9495
split-complementary
#5B1F95 #94951F #1F9520
monochromatic
#1D0A30 #3C1462 #5B1F95 #7A2AC8 #9853DB

Accessibility & contrast

On white

10.12
#5B1F95 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.07
#5B1F95 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B1F95
10.12:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B1F95#FFFFFF#000000##FFFFFF
##5B1F951.0010.122.0710.12
#FFFFFF10.121.0021.001.00
#0000002.0721.001.0021.00
##FFFFFF10.121.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004198
Deuteranopia (green-blind)
#004193
Tritanopia (blue-blind)
#4E3E5A
Achromatopsia (no color)
#424242

Design tokens & code

CSS
--color: #5b1f95;
/* rgb */ color: rgb(91, 31, 149);
/* oklch */ color: oklch(40.0% 0.178 301.6);
Tailwind
colors: {
  custom: {
    50: '#8f62b5',
    500: '#5b1f95',
    950: '#000000',
  },
}
SCSS
$custom: #5b1f95;
$custom-light: #8f62b5;
$custom-dark: #000000;
JSON
{
  "hex": "#5b1f95",
  "rgb": {
    "r": 91,
    "g": 31,
    "b": 149
  },
  "hsl": {
    "h": 270.508,
    "s": 65.556,
    "l": 35.294
  },
  "oklch": {
    "l": 0.3997,
    "c": 0.17807,
    "h": 301.6
  },
  "luminance": 0.05374
}

Semantic roles & 50–950 ramp

primary
#5B1F95
secondary
#87BF51
accent
#E93F92
background
#F9F6FB
surface
#F1EBF6
border
#CBC6D0
text
#0D0511
muted
#7E7A80

Preview Lab

Preview with #5B1F95

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

Preview Lab → · Contrast checker → · Palette generator →

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