#5F2DA6#5F2DA6

#5F2DA6 is a dark, vivid violet. Relative luminance 0.071; OKLCH L 43.5% C 0.182 H 297.0°. Best body text is #FFFFFF at 8.70:1 contrast (WCAG AA passes).

Color values

HEX#5F2DA6
RGBrgb(95, 45, 166)
HSLhsl(265, 57%, 41%)
HSVhsv(265, 73%, 65%)
CMYKcmyk(42.8%, 72.9%, 0%, 34.9%)
CIE-LABlab(31.95, 47.86, -56.61)
CIE-LCHlch(31.95, 74.12, 310.21°)
OKLaboklab(43.47% 0.0825 -0.1619)
OKLCHoklch(43.47% 0.182 297)
XYZxyz(12.5388, 7.0626, 36.7716)
Luminance0.0706 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5F2DA6 #74A62D
analogous
#2D38A6 #5F2DA6 #9C2DA6
triadic
#5F2DA6 #A65F2D #2DA65F
tetradic
#5F2DA6 #A62D38 #74A62D #2DA69C
square
#5F2DA6 #A62D38 #74A62D #2DA69C
split-complementary
#5F2DA6 #A69C2D #38A62D
monochromatic
#281346 #432076 #5F2DA6 #7C44CC #9E74D9

Accessibility & contrast

On white

8.70
#5F2DA6 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.41
#5F2DA6 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5F2DA6
8.70:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5F2DA6#FFFFFF#000000##FFFFFF
##5F2DA61.008.702.418.70
#FFFFFF8.701.0021.001.00
#0000002.4121.001.0021.00
##FFFFFF8.701.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CAA
Deuteranopia (green-blind)
#004AA4
Tritanopia (blue-blind)
#4D4C67
Achromatopsia (no color)
#4B4B4B

Design tokens & code

CSS
--color: #5f2da6;
/* rgb */ color: rgb(95, 45, 166);
/* oklch */ color: oklch(43.5% 0.182 297.0);
Tailwind
colors: {
  custom: {
    50: '#936bc1',
    500: '#5f2da6',
    950: '#000000',
  },
}
SCSS
$custom: #5f2da6;
$custom-light: #936bc1;
$custom-dark: #000000;
JSON
{
  "hex": "#5f2da6",
  "rgb": {
    "r": 95,
    "g": 45,
    "b": 166
  },
  "hsl": {
    "h": 264.793,
    "s": 57.346,
    "l": 41.373
  },
  "oklch": {
    "l": 0.43469,
    "c": 0.18168,
    "h": 297
  },
  "luminance": 0.07063
}

Semantic roles & 50–950 ramp

primary
#5F2DA6
secondary
#9FC16E
accent
#E147A1
background
#F9F6FC
surface
#F2EBF8
border
#CCC6D1
text
#0E0712
muted
#7E7A81

Preview Lab

Preview with #5F2DA6

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

Preview Lab → · Contrast checker → · Palette generator →

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