#5F158A#5F158A

#5F158A is a dark, vivid violet. Relative luminance 0.048; OKLCH L 38.7% C 0.177 H 308.4°. Best body text is #FFFFFF at 10.71:1 contrast (WCAG AA passes).

Color values

HEX#5F158A
RGBrgb(95, 21, 138)
HSLhsl(278, 74%, 31%)
HSVhsv(278, 85%, 54%)
CMYKcmyk(31.2%, 84.8%, 0%, 45.9%)
CIE-LABlab(26.17, 50.87, -48.88)
CIE-LCHlch(26.17, 70.55, 316.15°)
OKLaboklab(38.68% 0.1103 -0.139)
OKLCHoklch(38.68% 0.177 308.4)
XYZxyz(9.5740, 4.8044, 24.4628)
Luminance0.0480 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5F158A #408A15
analogous
#24158A #5F158A #8A157A
triadic
#5F158A #8A5F15 #158A5F
tetradic
#5F158A #8A2415 #408A15 #157A8A
square
#5F158A #8A2415 #408A15 #157A8A
split-complementary
#5F158A #7A8A15 #158A24
monochromatic
#160520 #3A0D55 #5F158A #841DBF #A339E1

Accessibility & contrast

On white

10.71
#5F158A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #5F158A
10.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5F158A#FFFFFF#000000##FFFFFF
##5F158A1.0010.711.9610.71
#FFFFFF10.711.0021.001.00
#0000001.9621.001.0021.00
##FFFFFF10.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003B8D
Deuteranopia (green-blind)
#003F88
Tritanopia (blue-blind)
#583551
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #5f158a;
/* rgb */ color: rgb(95, 21, 138);
/* oklch */ color: oklch(38.7% 0.177 308.4);
Tailwind
colors: {
  custom: {
    50: '#915ead',
    500: '#5f158a',
    950: '#000000',
  },
}
SCSS
$custom: #5f158a;
$custom-light: #915ead;
$custom-dark: #000000;
JSON
{
  "hex": "#5f158a",
  "rgb": {
    "r": 95,
    "g": 21,
    "b": 138
  },
  "hsl": {
    "h": 277.949,
    "s": 73.585,
    "l": 31.176
  },
  "oklch": {
    "l": 0.38683,
    "c": 0.17748,
    "h": 308.4
  },
  "luminance": 0.04804
}

Semantic roles & 50–950 ramp

primary
#5F158A
secondary
#6CBE3D
accent
#F0387B
background
#F9F5FA
surface
#F2EAF4
border
#CCC6CE
text
#0D0510
muted
#7E797F

Preview Lab

Preview with #5F158A

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

Preview Lab → · Contrast checker → · Palette generator →

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