#5A1157#5A1157

#5A1157 is a dark, vivid purple. Relative luminance 0.033; OKLCH L 33.7% C 0.133 H 329.9°. Best body text is #FFFFFF at 12.71:1 contrast (WCAG AA passes).

Color values

HEX#5A1157
RGBrgb(90, 17, 87)
HSLhsl(302, 68%, 21%)
HSVhsv(302, 81%, 35%)
CMYKcmyk(0%, 81.1%, 3.3%, 64.7%)
CIE-LABlab(21.07, 40.81, -24.24)
CIE-LCHlch(21.07, 47.47, 329.30°)
OKLaboklab(33.72% 0.1155 -0.067)
OKLCHoklch(33.72% 0.133 329.9)
XYZxyz(6.1372, 3.2632, 9.3216)
Luminance0.0326 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A1157 #115A14
analogous
#38115A #5A1157 #5A1132
triadic
#5A1157 #575A11 #11575A
tetradic
#5A1157 #5A3811 #115A14 #11325A
square
#5A1157 #5A3811 #115A14 #11325A
split-complementary
#5A1157 #325A11 #115A38
monochromatic
#1A0519 #270725 #5A1157 #8D1B89 #C124BB

Accessibility & contrast

On white

12.71
#5A1157 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.65
#5A1157 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A1157
12.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A1157#FFFFFF#000000##FFFFFF
##5A11571.0012.711.6512.71
#FFFFFF12.711.0021.001.00
#0000001.6521.001.0021.00
##FFFFFF12.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#062C59
Deuteranopia (green-blind)
#273655
Tritanopia (blue-blind)
#5E1B33
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #5a1157;
/* rgb */ color: rgb(90, 17, 87);
/* oklch */ color: oklch(33.7% 0.133 329.9);
Tailwind
colors: {
  custom: {
    50: '#8c5987',
    500: '#5a1157',
    950: '#000000',
  },
}
SCSS
$custom: #5a1157;
$custom-light: #8c5987;
$custom-dark: #000000;
JSON
{
  "hex": "#5a1157",
  "rgb": {
    "r": 90,
    "g": 17,
    "b": 87
  },
  "hsl": {
    "h": 302.466,
    "s": 68.224,
    "l": 20.98
  },
  "oklch": {
    "l": 0.33724,
    "c": 0.13347,
    "h": 329.9
  },
  "luminance": 0.03263
}

Semantic roles & 50–950 ramp

primary
#5A1157
secondary
#349338
accent
#EB443D
background
#F8F5F8
surface
#F0E9EF
border
#CBC5CA
text
#0C040B
muted
#7D797C

Preview Lab

Preview with #5A1157

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

Preview Lab → · Contrast checker → · Palette generator →

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