#5A126F#5A126F

#5A126F is a dark, vivid purple. Relative luminance 0.038; OKLCH L 35.5% C 0.154 H 317.0°. Best body text is #FFFFFF at 11.99:1 contrast (WCAG AA passes).

Color values

HEX#5A126F
RGBrgb(90, 18, 111)
HSLhsl(286, 72%, 25%)
HSVhsv(286, 84%, 44%)
CMYKcmyk(18.9%, 83.8%, 0%, 56.5%)
CIE-LABlab(22.84, 45.13, -37.18)
CIE-LCHlch(22.84, 58.47, 320.52°)
OKLaboklab(35.51% 0.1122 -0.1048)
OKLCHoklch(35.51% 0.154 317)
XYZxyz(7.3016, 3.7543, 15.3759)
Luminance0.0375 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A126F #276F12
analogous
#2C126F #5A126F #6F1255
triadic
#5A126F #6F5A12 #126F5A
tetradic
#5A126F #6F2C12 #276F12 #12556F
square
#5A126F #6F2C12 #276F12 #12556F
split-complementary
#5A126F #556F12 #126F2C
monochromatic
#15041A #2F093A #5A126F #851BA4 #AF23D8

Accessibility & contrast

On white

11.99
#5A126F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.75
#5A126F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A126F
11.99:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A126F#FFFFFF#000000##FFFFFF
##5A126F1.0011.991.7511.99
#FFFFFF11.991.0021.001.00
#0000001.7521.001.0021.00
##FFFFFF11.991.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003271
Deuteranopia (green-blind)
#13396D
Tritanopia (blue-blind)
#592841
Achromatopsia (no color)
#363636

Design tokens & code

CSS
--color: #5a126f;
/* rgb */ color: rgb(90, 18, 111);
/* oklch */ color: oklch(35.5% 0.154 317.0);
Tailwind
colors: {
  custom: {
    50: '#8c5a99',
    500: '#5a126f',
    950: '#000000',
  },
}
SCSS
$custom: #5a126f;
$custom-light: #8c5a99;
$custom-dark: #000000;
JSON
{
  "hex": "#5a126f",
  "rgb": {
    "r": 90,
    "g": 18,
    "b": 111
  },
  "hsl": {
    "h": 286.452,
    "s": 72.093,
    "l": 25.294
  },
  "oklch": {
    "l": 0.3551,
    "c": 0.15355,
    "h": 317
  },
  "luminance": 0.03754
}

Semantic roles & 50–950 ramp

primary
#5A126F
secondary
#50A637
accent
#EF3962
background
#F8F5F9
surface
#F0E9F2
border
#CBC5CC
text
#0C040E
muted
#7D797E

Preview Lab

Preview with #5A126F

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

Preview Lab → · Contrast checker → · Palette generator →

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