#5F2197#5F2197

#5F2197 is a dark, vivid violet. Relative luminance 0.058; OKLCH L 40.8% C 0.179 H 302.9°. Best body text is #FFFFFF at 9.76:1 contrast (WCAG AA passes).

Color values

HEX#5F2197
RGBrgb(95, 33, 151)
HSLhsl(272, 64%, 36%)
HSVhsv(272, 78%, 59%)
CMYKcmyk(37.1%, 78.1%, 0%, 40.8%)
CIE-LABlab(28.79, 49.49, -52.65)
CIE-LCHlch(28.79, 72.26, 313.23°)
OKLaboklab(40.85% 0.0971 -0.1502)
OKLCHoklch(40.85% 0.179 302.9)
XYZxyz(10.8478, 5.7550, 29.8115)
Luminance0.0575 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5F2197 #599721
analogous
#242197 #5F2197 #972194
triadic
#5F2197 #975F21 #21975F
tetradic
#5F2197 #972421 #599721 #219497
square
#5F2197 #972421 #599721 #219497
split-complementary
#5F2197 #949721 #219724
monochromatic
#200B33 #3F1665 #5F2197 #7F2CC9 #9D58DA

Accessibility & contrast

On white

9.76
#5F2197 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #5F2197
9.76:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5F2197#FFFFFF#000000##FFFFFF
##5F21971.009.762.159.76
#FFFFFF9.761.0021.001.00
#0000002.1521.001.0021.00
##FFFFFF9.761.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00439A
Deuteranopia (green-blind)
#004395
Tritanopia (blue-blind)
#53405B
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #5f2197;
/* rgb */ color: rgb(95, 33, 151);
/* oklch */ color: oklch(40.8% 0.179 302.9);
Tailwind
colors: {
  custom: {
    50: '#9264b6',
    500: '#5f2197',
    950: '#000000',
  },
}
SCSS
$custom: #5f2197;
$custom-light: #9264b6;
$custom-dark: #000000;
JSON
{
  "hex": "#5f2197",
  "rgb": {
    "r": 95,
    "g": 33,
    "b": 151
  },
  "hsl": {
    "h": 271.525,
    "s": 64.13,
    "l": 36.078
  },
  "oklch": {
    "l": 0.4085,
    "c": 0.17884,
    "h": 302.9
  },
  "luminance": 0.05755
}

Semantic roles & 50–950 ramp

primary
#5F2197
secondary
#87BE55
accent
#E74190
background
#F9F6FB
surface
#F2EBF6
border
#CCC6D0
text
#0E0611
muted
#7E7A80

Preview Lab

Preview with #5F2197

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

Preview Lab → · Contrast checker → · Palette generator →

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