#5A2F96#5A2F96

#5A2F96 is a dark, vivid violet. Relative luminance 0.064; OKLCH L 41.8% C 0.160 H 298.3°. Best body text is #FFFFFF at 9.20:1 contrast (WCAG AA passes).

Color values

HEX#5A2F96
RGBrgb(90, 47, 150)
HSLhsl(265, 52%, 39%)
HSVhsv(265, 69%, 59%)
CMYKcmyk(40%, 68.7%, 0%, 41.2%)
CIE-LABlab(30.42, 41.61, -49.41)
CIE-LCHlch(30.42, 64.60, 310.11°)
OKLaboklab(41.84% 0.0759 -0.1409)
OKLCHoklch(41.84% 0.16 298.3)
XYZxyz(10.7366, 6.4085, 29.5196)
Luminance0.0641 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A2F96 #6B962F
analogous
#2F3796 #5A2F96 #8D2F96
triadic
#5A2F96 #965A2F #2F965A
tetradic
#5A2F96 #962F37 #6B962F #2F968D
square
#5A2F96 #962F37 #6B962F #2F968D
split-complementary
#5A2F96 #968D2F #37962F
monochromatic
#221239 #3E2067 #5A2F96 #763FC3 #976ED2

Accessibility & contrast

On white

9.20
#5A2F96 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.28
#5A2F96 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A2F96
9.20:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A2F96#FFFFFF#000000##FFFFFF
##5A2F961.009.202.289.20
#FFFFFF9.201.0021.001.00
#0000002.2821.001.0021.00
##FFFFFF9.201.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004899
Deuteranopia (green-blind)
#004794
Tritanopia (blue-blind)
#4C475E
Achromatopsia (no color)
#484848

Design tokens & code

CSS
--color: #5a2f96;
/* rgb */ color: rgb(90, 47, 150);
/* oklch */ color: oklch(41.8% 0.160 298.3);
Tailwind
colors: {
  custom: {
    50: '#8e6bb6',
    500: '#5a2f96',
    950: '#000000',
  },
}
SCSS
$custom: #5a2f96;
$custom-light: #8e6bb6;
$custom-dark: #000000;
JSON
{
  "hex": "#5a2f96",
  "rgb": {
    "r": 90,
    "g": 47,
    "b": 150
  },
  "hsl": {
    "h": 265.049,
    "s": 52.284,
    "l": 38.627
  },
  "oklch": {
    "l": 0.41841,
    "c": 0.16006,
    "h": 298.3
  },
  "luminance": 0.06409
}

Semantic roles & 50–950 ramp

primary
#5A2F96
secondary
#97B968
accent
#DC4CA0
background
#F9F6FB
surface
#F1EBF6
border
#CBC6D0
text
#0D0711
muted
#7E7A80

Preview Lab

Preview with #5A2F96

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

Preview Lab → · Contrast checker → · Palette generator →

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