#5A1E9D#5A1E9D

#5A1E9D is a dark, vivid violet. Relative luminance 0.055; OKLCH L 40.5% C 0.187 H 298.8°. Best body text is #FFFFFF at 9.96:1 contrast (WCAG AA passes).

Color values

HEX#5A1E9D
RGBrgb(90, 30, 157)
HSLhsl(268, 68%, 37%)
HSVhsv(268, 81%, 62%)
CMYKcmyk(42.7%, 80.9%, 0%, 38.4%)
CIE-LABlab(28.21, 51.35, -57.29)
CIE-LCHlch(28.21, 76.93, 311.87°)
OKLaboklab(40.46% 0.0903 -0.164)
OKLCHoklch(40.46% 0.187 298.8)
XYZxyz(10.7650, 5.5364, 32.3932)
Luminance0.0554 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A1E9D #619D1E
analogous
#1E229D #5A1E9D #9A1E9D
triadic
#5A1E9D #9D5A1E #1E9D5A
tetradic
#5A1E9D #9D1E22 #619D1E #1E9D9A
square
#5A1E9D #9D1E22 #619D1E #1E9D9A
split-complementary
#5A1E9D #9D9A1E #229D1E
monochromatic
#1F0A36 #3D146A #5A1E9D #7728D0 #9757DF

Accessibility & contrast

On white

9.96
#5A1E9D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.11
#5A1E9D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A1E9D
9.96:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A1E9D#FFFFFF#000000##FFFFFF
##5A1E9D1.009.962.119.96
#FFFFFF9.961.0021.001.00
#0000002.1121.001.0021.00
##FFFFFF9.961.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0043A0
Deuteranopia (green-blind)
#00419B
Tritanopia (blue-blind)
#49425E
Achromatopsia (no color)
#434343

Design tokens & code

CSS
--color: #5a1e9d;
/* rgb */ color: rgb(90, 30, 157);
/* oklch */ color: oklch(40.5% 0.187 298.8);
Tailwind
colors: {
  custom: {
    50: '#9062bb',
    500: '#5a1e9d',
    950: '#000000',
  },
}
SCSS
$custom: #5a1e9d;
$custom-light: #9062bb;
$custom-dark: #000000;
JSON
{
  "hex": "#5a1e9d",
  "rgb": {
    "r": 90,
    "g": 30,
    "b": 157
  },
  "hsl": {
    "h": 268.346,
    "s": 67.914,
    "l": 36.667
  },
  "oklch": {
    "l": 0.40464,
    "c": 0.18718,
    "h": 298.8
  },
  "luminance": 0.05537
}

Semantic roles & 50–950 ramp

primary
#5A1E9D
secondary
#8EC254
accent
#EB3D99
background
#F9F6FB
surface
#F2EBF6
border
#CCC6D0
text
#0D0512
muted
#7E7A81

Preview Lab

Preview with #5A1E9D

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

Preview Lab → · Contrast checker → · Palette generator →

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