#5A187E#5A187E

#5A187E is a dark, vivid violet. Relative luminance 0.043; OKLCH L 37.2% C 0.162 H 310.0°. Best body text is #FFFFFF at 11.25:1 contrast (WCAG AA passes).

Color values

HEX#5A187E
RGBrgb(90, 24, 126)
HSLhsl(279, 68%, 29%)
HSVhsv(279, 81%, 49%)
CMYKcmyk(28.6%, 81%, 0%, 50.6%)
CIE-LABlab(24.74, 46.28, -43.69)
CIE-LCHlch(24.74, 63.64, 316.65°)
OKLaboklab(37.22% 0.1039 -0.124)
OKLCHoklch(37.22% 0.162 310)
XYZxyz(8.3082, 4.3335, 20.1334)
Luminance0.0433 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A187E #3C7E18
analogous
#27187E #5A187E #7E186F
triadic
#5A187E #7E5A18 #187E5A
tetradic
#5A187E #7E2718 #3C7E18 #186F7E
square
#5A187E #7E2718 #3C7E18 #186F7E
split-complementary
#5A187E #6F7E18 #187E27
monochromatic
#12051A #350E4B #5A187E #7F22B1 #A037D9

Accessibility & contrast

On white

11.25
#5A187E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.87
#5A187E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A187E
11.25:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A187E#FFFFFF#000000##FFFFFF
##5A187E1.0011.251.8711.25
#FFFFFF11.251.0021.001.00
#0000001.8721.001.0021.00
##FFFFFF11.251.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003881
Deuteranopia (green-blind)
#003C7C
Tritanopia (blue-blind)
#55314B
Achromatopsia (no color)
#3B3B3B

Design tokens & code

CSS
--color: #5a187e;
/* rgb */ color: rgb(90, 24, 126);
/* oklch */ color: oklch(37.2% 0.162 310.0);
Tailwind
colors: {
  custom: {
    50: '#8d5ea4',
    500: '#5a187e',
    950: '#000000',
  },
}
SCSS
$custom: #5a187e;
$custom-light: #8d5ea4;
$custom-dark: #000000;
JSON
{
  "hex": "#5a187e",
  "rgb": {
    "r": 90,
    "g": 24,
    "b": 126
  },
  "hsl": {
    "h": 278.824,
    "s": 68,
    "l": 29.412
  },
  "oklch": {
    "l": 0.37217,
    "c": 0.16176,
    "h": 310
  },
  "luminance": 0.04333
}

Semantic roles & 50–950 ramp

primary
#5A187E
secondary
#68B23F
accent
#EB3D7A
background
#F9F5FA
surface
#F1E9F4
border
#CBC5CE
text
#0D050F
muted
#7E797F

Preview Lab

Preview with #5A187E

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

Preview Lab → · Contrast checker → · Palette generator →

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