#5A187D#5A187D

#5A187D is a dark, vivid violet. Relative luminance 0.043; OKLCH L 37.1% C 0.161 H 310.4°. Best body text is #FFFFFF at 11.28:1 contrast (WCAG AA passes).

Color values

HEX#5A187D
RGBrgb(90, 24, 125)
HSLhsl(279, 68%, 29%)
HSVhsv(279, 81%, 49%)
CMYKcmyk(28%, 80.8%, 0%, 51%)
CIE-LABlab(24.66, 46.05, -43.19)
CIE-LCHlch(24.66, 63.14, 316.84°)
OKLaboklab(37.14% 0.1041 -0.1225)
OKLCHoklch(37.14% 0.161 310.4)
XYZxyz(8.2440, 4.3078, 19.7953)
Luminance0.0431 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A187D #3B7D18
analogous
#28187D #5A187D #7D186E
triadic
#5A187D #7D5A18 #187D5A
tetradic
#5A187D #7D2818 #3B7D18 #186E7D
square
#5A187D #7D2818 #3B7D18 #186E7D
split-complementary
#5A187D #6E7D18 #187D28
monochromatic
#12051A #350E4A #5A187D #7F22B0 #A137D9

Accessibility & contrast

On white

11.28
#5A187D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.86
#5A187D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A187D
11.28:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A187D#FFFFFF#000000##FFFFFF
##5A187D1.0011.281.8611.28
#FFFFFF11.281.0021.001.00
#0000001.8621.001.0021.00
##FFFFFF11.281.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003880
Deuteranopia (green-blind)
#003C7B
Tritanopia (blue-blind)
#55314A
Achromatopsia (no color)
#3B3B3B

Design tokens & code

CSS
--color: #5a187d;
/* rgb */ color: rgb(90, 24, 125);
/* oklch */ color: oklch(37.1% 0.161 310.4);
Tailwind
colors: {
  custom: {
    50: '#8d5da3',
    500: '#5a187d',
    950: '#000000',
  },
}
SCSS
$custom: #5a187d;
$custom-light: #8d5da3;
$custom-dark: #000000;
JSON
{
  "hex": "#5a187d",
  "rgb": {
    "r": 90,
    "g": 24,
    "b": 125
  },
  "hsl": {
    "h": 279.208,
    "s": 67.785,
    "l": 29.216
  },
  "oklch": {
    "l": 0.37135,
    "c": 0.16078,
    "h": 310.4
  },
  "luminance": 0.04308
}

Semantic roles & 50–950 ramp

primary
#5A187D
secondary
#67B23F
accent
#EB3D79
background
#F9F5FA
surface
#F1E9F4
border
#CBC5CE
text
#0D050F
muted
#7E797F

Preview Lab

Preview with #5A187D

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

Preview Lab → · Contrast checker → · Palette generator →

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