#5A1782#5A1782

#5A1782 is a dark, vivid violet. Relative luminance 0.044; OKLCH L 37.5% C 0.167 H 308.5°. Best body text is #FFFFFF at 11.17:1 contrast (WCAG AA passes).

Color values

HEX#5A1782
RGBrgb(90, 23, 130)
HSLhsl(278, 70%, 30%)
HSVhsv(278, 82%, 51%)
CMYKcmyk(30.8%, 82.3%, 0%, 49%)
CIE-LABlab(24.95, 47.55, -45.89)
CIE-LCHlch(24.95, 66.08, 316.02°)
OKLaboklab(37.46% 0.1038 -0.1304)
OKLCHoklch(37.46% 0.167 308.5)
XYZxyz(8.5513, 4.3983, 21.5132)
Luminance0.0440 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A1782 #3F8217
analogous
#241782 #5A1782 #821775
triadic
#5A1782 #825A17 #17825A
tetradic
#5A1782 #822417 #3F8217 #177582
square
#5A1782 #822417 #3F8217 #177582
split-complementary
#5A1782 #758217 #178224
monochromatic
#12051A #360E4E #5A1782 #7E20B6 #9E38DC

Accessibility & contrast

On white

11.17
#5A1782 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.88
#5A1782 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A1782
11.17:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A1782#FFFFFF#000000##FFFFFF
##5A17821.0011.171.8811.17
#FFFFFF11.171.0021.001.00
#0000001.8821.001.0021.00
##FFFFFF11.171.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003985
Deuteranopia (green-blind)
#003C80
Tritanopia (blue-blind)
#54334D
Achromatopsia (no color)
#3B3B3B

Design tokens & code

CSS
--color: #5a1782;
/* rgb */ color: rgb(90, 23, 130);
/* oklch */ color: oklch(37.5% 0.167 308.5);
Tailwind
colors: {
  custom: {
    50: '#8d5da7',
    500: '#5a1782',
    950: '#000000',
  },
}
SCSS
$custom: #5a1782;
$custom-light: #8d5da7;
$custom-dark: #000000;
JSON
{
  "hex": "#5a1782",
  "rgb": {
    "r": 90,
    "g": 23,
    "b": 130
  },
  "hsl": {
    "h": 277.57,
    "s": 69.935,
    "l": 30
  },
  "oklch": {
    "l": 0.37461,
    "c": 0.16667,
    "h": 308.5
  },
  "luminance": 0.04398
}

Semantic roles & 50–950 ramp

primary
#5A1782
secondary
#6BB63E
accent
#ED3B7D
background
#F9F5FA
surface
#F1E9F4
border
#CBC5CE
text
#0D050F
muted
#7E797F

Preview Lab

Preview with #5A1782

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

Preview Lab → · Contrast checker → · Palette generator →

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