#5A127F#5A127F

#5A127F is a dark, vivid violet. Relative luminance 0.041; OKLCH L 36.8% C 0.168 H 310.1°. Best body text is #FFFFFF at 11.49:1 contrast (WCAG AA passes).

Color values

HEX#5A127F
RGBrgb(90, 18, 127)
HSLhsl(280, 75%, 28%)
HSVhsv(280, 86%, 50%)
CMYKcmyk(29.1%, 85.8%, 0%, 50.2%)
CIE-LABlab(24.13, 48.54, -45.33)
CIE-LCHlch(24.13, 66.42, 316.96°)
OKLaboklab(36.81% 0.1084 -0.1287)
OKLCHoklch(36.81% 0.168 310.1)
XYZxyz(8.2628, 4.1388, 20.4381)
Luminance0.0414 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A127F #377F12
analogous
#23127F #5A127F #7F126D
triadic
#5A127F #7F5A12 #127F5A
tetradic
#5A127F #7F2312 #377F12 #126D7F
square
#5A127F #7F2312 #377F12 #126D7F
split-complementary
#5A127F #6D7F12 #127F23
monochromatic
#13041B #340A49 #5A127F #801AB5 #A32BE1

Accessibility & contrast

On white

11.49
#5A127F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.83
#5A127F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A127F
11.49:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A127F#FFFFFF#000000##FFFFFF
##5A127F1.0011.491.8311.49
#FFFFFF11.491.0021.001.00
#0000001.8321.001.0021.00
##FFFFFF11.491.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003682
Deuteranopia (green-blind)
#003A7D
Tritanopia (blue-blind)
#552F4A
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #5a127f;
/* rgb */ color: rgb(90, 18, 127);
/* oklch */ color: oklch(36.8% 0.168 310.1);
Tailwind
colors: {
  custom: {
    50: '#8d5ba5',
    500: '#5a127f',
    950: '#000000',
  },
}
SCSS
$custom: #5a127f;
$custom-light: #8d5ba5;
$custom-dark: #000000;
JSON
{
  "hex": "#5a127f",
  "rgb": {
    "r": 90,
    "g": 18,
    "b": 127
  },
  "hsl": {
    "h": 279.633,
    "s": 75.172,
    "l": 28.431
  },
  "oklch": {
    "l": 0.3681,
    "c": 0.16833,
    "h": 310.1
  },
  "luminance": 0.04139
}

Semantic roles & 50–950 ramp

primary
#5A127F
secondary
#62B538
accent
#F23676
background
#F9F5FA
surface
#F1E9F4
border
#CBC5CE
text
#0D040F
muted
#7E797F

Preview Lab

Preview with #5A127F

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

Preview Lab → · Contrast checker → · Palette generator →

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