#5A337D#5A337D

#5A337D is a dark, vivid violet. Relative luminance 0.060; OKLCH L 40.6% C 0.123 H 306.0°. Best body text is #FFFFFF at 9.53:1 contrast (WCAG AA passes).

Color values

HEX#5A337D
RGBrgb(90, 51, 125)
HSLhsl(272, 42%, 35%)
HSVhsv(272, 59%, 49%)
CMYKcmyk(28%, 59.2%, 0%, 51%)
CIE-LABlab(29.47, 32.76, -35.45)
CIE-LCHlch(29.47, 48.27, 312.75°)
OKLaboklab(40.59% 0.0725 -0.0999)
OKLCHoklch(40.59% 0.123 306)
XYZxyz(9.1012, 6.0221, 20.0810)
Luminance0.0602 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A337D #567D33
analogous
#35337D #5A337D #7D337B
triadic
#5A337D #7D5A33 #337D5A
tetradic
#5A337D #7D3533 #567D33 #337B7D
square
#5A337D #7D3533 #567D33 #337B7D
split-complementary
#5A337D #7B7D33 #337D35
monochromatic
#1B1026 #3B2152 #5A337D #7945A8 #9869C2

Accessibility & contrast

On white

9.53
#5A337D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.20
#5A337D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A337D
9.53:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A337D#FFFFFF#000000##FFFFFF
##5A337D1.009.532.209.53
#FFFFFF9.531.0021.001.00
#0000002.2021.001.0021.00
##FFFFFF9.531.0021.001.00

Color blindness preview

Protanopia (red-blind)
#17447F
Deuteranopia (green-blind)
#26467B
Tritanopia (blue-blind)
#544153
Achromatopsia (no color)
#454545

Design tokens & code

CSS
--color: #5a337d;
/* rgb */ color: rgb(90, 51, 125);
/* oklch */ color: oklch(40.6% 0.123 306.0);
Tailwind
colors: {
  custom: {
    50: '#8b6ca3',
    500: '#5a337d',
    950: '#000000',
  },
}
SCSS
$custom: #5a337d;
$custom-light: #8b6ca3;
$custom-dark: #000000;
JSON
{
  "hex": "#5a337d",
  "rgb": {
    "r": 90,
    "g": 51,
    "b": 125
  },
  "hsl": {
    "h": 271.622,
    "s": 42.045,
    "l": 34.51
  },
  "oklch": {
    "l": 0.40585,
    "c": 0.12345,
    "h": 306
  },
  "luminance": 0.06022
}

Semantic roles & 50–950 ramp

primary
#5A337D
secondary
#84AA62
accent
#D25691
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0C070F
muted
#7D7A7F

Preview Lab

Preview with #5A337D

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

Preview Lab → · Contrast checker → · Palette generator →

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