#5A138E#5A138E

#5A138E is a dark, vivid violet. Relative luminance 0.046; OKLCH L 38.2% C 0.182 H 304.6°. Best body text is #FFFFFF at 10.95:1 contrast (WCAG AA passes).

Color values

HEX#5A138E
RGBrgb(90, 19, 142)
HSLhsl(275, 76%, 32%)
HSVhsv(275, 87%, 56%)
CMYKcmyk(36.6%, 86.6%, 0%, 44.3%)
CIE-LABlab(25.54, 51.60, -52.43)
CIE-LCHlch(25.54, 73.56, 314.54°)
OKLaboklab(38.2% 0.103 -0.1496)
OKLCHoklch(38.2% 0.182 304.6)
XYZxyz(9.3307, 4.5924, 25.9808)
Luminance0.0459 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A138E #478E13
analogous
#1C138E #5A138E #8E1385
triadic
#5A138E #8E5A13 #138E5A
tetradic
#5A138E #8E1C13 #478E13 #13858E
square
#5A138E #8E1C13 #478E13 #13858E
split-complementary
#5A138E #858E13 #138E1C
monochromatic
#160522 #380C58 #5A138E #7C1AC4 #9B37E4

Accessibility & contrast

On white

10.95
#5A138E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.92
#5A138E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A138E
10.95:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A138E#FFFFFF#000000##FFFFFF
##5A138E1.0010.951.9210.95
#FFFFFF10.951.0021.001.00
#0000001.9221.001.0021.00
##FFFFFF10.951.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003B91
Deuteranopia (green-blind)
#003C8C
Tritanopia (blue-blind)
#503753
Achromatopsia (no color)
#3D3D3D

Design tokens & code

CSS
--color: #5a138e;
/* rgb */ color: rgb(90, 19, 142);
/* oklch */ color: oklch(38.2% 0.182 304.6);
Tailwind
colors: {
  custom: {
    50: '#8f5db0',
    500: '#5a138e',
    950: '#000000',
  },
}
SCSS
$custom: #5a138e;
$custom-light: #8f5db0;
$custom-dark: #000000;
JSON
{
  "hex": "#5a138e",
  "rgb": {
    "r": 90,
    "g": 19,
    "b": 142
  },
  "hsl": {
    "h": 274.634,
    "s": 76.398,
    "l": 31.569
  },
  "oklch": {
    "l": 0.38196,
    "c": 0.18165,
    "h": 304.6
  },
  "luminance": 0.04592
}

Semantic roles & 50–950 ramp

primary
#5A138E
secondary
#74C23B
accent
#F33585
background
#F9F5FA
surface
#F1E9F5
border
#CBC5CF
text
#0D0511
muted
#7E7980

Preview Lab

Preview with #5A138E

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

Preview Lab → · Contrast checker → · Palette generator →

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