#331580#331580

#331580 is a dark, vivid violet. Relative luminance 0.028; OKLCH L 32.3% C 0.162 H 285.7°. Best body text is #FFFFFF at 13.46:1 contrast (WCAG AA passes).

Color values

HEX#331580
RGBrgb(51, 21, 128)
HSLhsl(257, 72%, 29%)
HSVhsv(257, 84%, 50%)
CMYKcmyk(60.2%, 83.6%, 0%, 49.8%)
CIE-LABlab(19.22, 41.93, -54.22)
CIE-LCHlch(19.22, 68.54, 307.72°)
OKLaboklab(32.27% 0.044 -0.1562)
OKLCHoklch(32.27% 0.162 285.7)
XYZxyz(5.5285, 2.7983, 20.6667)
Luminance0.0280 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331580 #628015
analogous
#152D80 #331580 #691580
triadic
#331580 #803315 #158033
tetradic
#331580 #80152D #628015 #158069
square
#331580 #80152D #628015 #158069
split-complementary
#331580 #806915 #2D8015
monochromatic
#0A041A #1E0C4B #331580 #481EB5 #6232DD

Accessibility & contrast

On white

13.46
#331580 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.56
#331580 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331580
13.46:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331580#FFFFFF#000000##FFFFFF
##3315801.0013.461.5613.46
#FFFFFF13.461.0021.001.00
#0000001.5621.001.0021.00
##FFFFFF13.461.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003183
Deuteranopia (green-blind)
#002B7E
Tritanopia (blue-blind)
#08364B
Achromatopsia (no color)
#2F2F2F

Design tokens & code

CSS
--color: #331580;
/* rgb */ color: rgb(51, 21, 128);
/* oklch */ color: oklch(32.3% 0.162 285.7);
Tailwind
colors: {
  custom: {
    50: '#7558a6',
    500: '#331580',
    950: '#000000',
  },
}
SCSS
$custom: #331580;
$custom-light: #7558a6;
$custom-dark: #000000;
JSON
{
  "hex": "#331580",
  "rgb": {
    "r": 51,
    "g": 21,
    "b": 128
  },
  "hsl": {
    "h": 256.822,
    "s": 71.812,
    "l": 29.216
  },
  "oklch": {
    "l": 0.32271,
    "c": 0.16227,
    "h": 285.7
  },
  "luminance": 0.02799
}

Semantic roles & 50–950 ramp

primary
#331580
secondary
#93B53C
accent
#EF39BC
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #331580

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

Preview Lab → · Contrast checker → · Palette generator →

#331580 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva