#5F1D9D#5F1D9D

#5F1D9D is a dark, vivid violet. Relative luminance 0.057; OKLCH L 41.0% C 0.189 H 301.5°. Best body text is #FFFFFF at 9.77:1 contrast (WCAG AA passes).

Color values

HEX#5F1D9D
RGBrgb(95, 29, 157)
HSLhsl(271, 69%, 36%)
HSVhsv(271, 82%, 62%)
CMYKcmyk(39.5%, 81.5%, 0%, 38.4%)
CIE-LABlab(28.76, 52.50, -56.36)
CIE-LCHlch(28.76, 77.03, 312.97°)
OKLaboklab(40.99% 0.0987 -0.161)
OKLCHoklch(40.99% 0.189 301.5)
XYZxyz(11.2430, 5.7459, 32.4085)
Luminance0.0575 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5F1D9D #5B9D1D
analogous
#1F1D9D #5F1D9D #9D1D9B
triadic
#5F1D9D #9D5F1D #1D9D5F
tetradic
#5F1D9D #9D1F1D #5B9D1D #1D9B9D
square
#5F1D9D #9D1F1D #5B9D1D #1D9B9D
split-complementary
#5F1D9D #9B9D1D #1D9D1F
monochromatic
#200A36 #401369 #5F1D9D #7E27D1 #9C55E0

Accessibility & contrast

On white

9.77
#5F1D9D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.15
#5F1D9D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5F1D9D
9.77:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5F1D9D#FFFFFF#000000##FFFFFF
##5F1D9D1.009.772.159.77
#FFFFFF9.771.0021.001.00
#0000002.1521.001.0021.00
##FFFFFF9.771.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0043A0
Deuteranopia (green-blind)
#00439B
Tritanopia (blue-blind)
#51415E
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #5f1d9d;
/* rgb */ color: rgb(95, 29, 157);
/* oklch */ color: oklch(41.0% 0.189 301.5);
Tailwind
colors: {
  custom: {
    50: '#9362bb',
    500: '#5f1d9d',
    950: '#000000',
  },
}
SCSS
$custom: #5f1d9d;
$custom-light: #9362bb;
$custom-dark: #000000;
JSON
{
  "hex": "#5f1d9d",
  "rgb": {
    "r": 95,
    "g": 29,
    "b": 157
  },
  "hsl": {
    "h": 270.938,
    "s": 68.817,
    "l": 36.471
  },
  "oklch": {
    "l": 0.40994,
    "c": 0.18886,
    "h": 301.5
  },
  "luminance": 0.05746
}

Semantic roles & 50–950 ramp

primary
#5F1D9D
secondary
#89C353
accent
#EC3C91
background
#F9F6FB
surface
#F2EBF6
border
#CCC6D0
text
#0E0612
muted
#7E7A81

Preview Lab

Preview with #5F1D9D

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

Preview Lab → · Contrast checker → · Palette generator →

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