#5A1258#5A1258

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

Color values

HEX#5A1258
RGBrgb(90, 18, 88)
HSLhsl(302, 67%, 21%)
HSVhsv(302, 80%, 35%)
CMYKcmyk(0%, 80%, 2.2%, 64.7%)
CIE-LABlab(21.25, 40.65, -24.62)
CIE-LCHlch(21.25, 47.52, 328.80°)
OKLaboklab(33.87% 0.1145 -0.0681)
OKLCHoklch(33.87% 0.133 329.3)
XYZxyz(6.1942, 3.3113, 9.5435)
Luminance0.0331 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A1258 #125A14
analogous
#38125A #5A1258 #5A1234
triadic
#5A1258 #585A12 #12585A
tetradic
#5A1258 #5A3812 #125A14 #12345A
square
#5A1258 #5A3812 #125A14 #12345A
split-complementary
#5A1258 #345A12 #125A38
monochromatic
#1A0519 #270826 #5A1258 #8D1C8A #C026BC

Accessibility & contrast

On white

12.63
#5A1258 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.66
#5A1258 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A1258
12.63:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A1258#FFFFFF#000000##FFFFFF
##5A12581.0012.631.6612.63
#FFFFFF12.631.0021.001.00
#0000001.6621.001.0021.00
##FFFFFF12.631.0021.001.00

Color blindness preview

Protanopia (red-blind)
#062D5A
Deuteranopia (green-blind)
#273656
Tritanopia (blue-blind)
#5D1D34
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #5a1258;
/* rgb */ color: rgb(90, 18, 88);
/* oklch */ color: oklch(33.9% 0.133 329.3);
Tailwind
colors: {
  custom: {
    50: '#8c5987',
    500: '#5a1258',
    950: '#000000',
  },
}
SCSS
$custom: #5a1258;
$custom-light: #8c5987;
$custom-dark: #000000;
JSON
{
  "hex": "#5a1258",
  "rgb": {
    "r": 90,
    "g": 18,
    "b": 88
  },
  "hsl": {
    "h": 301.667,
    "s": 66.667,
    "l": 21.176
  },
  "oklch": {
    "l": 0.33873,
    "c": 0.13319,
    "h": 329.3
  },
  "luminance": 0.03311
}

Semantic roles & 50–950 ramp

primary
#5A1258
secondary
#359338
accent
#EA433E
background
#F8F5F8
surface
#F0E9EF
border
#CBC5CA
text
#0C040B
muted
#7D797C

Preview Lab

Preview with #5A1258

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

Preview Lab → · Contrast checker → · Palette generator →

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