#5A2181#5A2181

#5A2181 is a dark, vivid violet. Relative luminance 0.048; OKLCH L 38.4% C 0.155 H 307.7°. Best body text is #FFFFFF at 10.66:1 contrast (WCAG AA passes).

Color values

HEX#5A2181
RGBrgb(90, 33, 129)
HSLhsl(276, 59%, 32%)
HSVhsv(276, 74%, 51%)
CMYKcmyk(30.2%, 74.4%, 0%, 49.4%)
CIE-LABlab(26.29, 43.23, -43.07)
CIE-LCHlch(26.29, 61.02, 315.10°)
OKLaboklab(38.38% 0.0945 -0.1222)
OKLCHoklch(38.38% 0.155 307.7)
XYZxyz(8.7219, 4.8465, 21.2406)
Luminance0.0485 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A2181 #488121
analogous
#2A2181 #5A2181 #812178
triadic
#5A2181 #815A21 #21815A
tetradic
#5A2181 #812A21 #488121 #217881
square
#5A2181 #812A21 #488121 #217881
split-complementary
#5A2181 #788121 #21812A
monochromatic
#160820 #381550 #5A2181 #7C2DB2 #9B4BD1

Accessibility & contrast

On white

10.66
#5A2181 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.97
#5A2181 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A2181
10.66:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A2181#FFFFFF#000000##FFFFFF
##5A21811.0010.661.9710.66
#FFFFFF10.661.0021.001.00
#0000001.9721.001.0021.00
##FFFFFF10.661.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003C84
Deuteranopia (green-blind)
#023F7F
Tritanopia (blue-blind)
#54374F
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #5a2181;
/* rgb */ color: rgb(90, 33, 129);
/* oklch */ color: oklch(38.4% 0.155 307.7);
Tailwind
colors: {
  custom: {
    50: '#8d62a6',
    500: '#5a2181',
    950: '#000000',
  },
}
SCSS
$custom: #5a2181;
$custom-light: #8d62a6;
$custom-dark: #000000;
JSON
{
  "hex": "#5a2181",
  "rgb": {
    "r": 90,
    "g": 33,
    "b": 129
  },
  "hsl": {
    "h": 275.625,
    "s": 59.259,
    "l": 31.765
  },
  "oklch": {
    "l": 0.38384,
    "c": 0.15452,
    "h": 307.7
  },
  "luminance": 0.04846
}

Semantic roles & 50–950 ramp

primary
#5A2181
secondary
#75B44A
accent
#E24585
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0D050F
muted
#7D7A7F

Preview Lab

Preview with #5A2181

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

Preview Lab → · Contrast checker → · Palette generator →

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