#311C84#311C84

#311C84 is a dark, vivid violet. Relative luminance 0.031; OKLCH L 33.3% C 0.161 H 282.5°. Best body text is #FFFFFF at 12.89:1 contrast (WCAG AA passes).

Color values

HEX#311C84
RGBrgb(49, 28, 132)
HSLhsl(252, 65%, 31%)
HSVhsv(252, 79%, 52%)
CMYKcmyk(62.9%, 78.8%, 0%, 48.2%)
CIE-LABlab(20.63, 39.47, -54.42)
CIE-LCHlch(20.63, 67.23, 305.95°)
OKLaboklab(33.34% 0.0349 -0.1569)
OKLCHoklch(33.34% 0.161 282.5)
XYZxyz(5.8454, 3.1490, 22.1251)
Luminance0.0315 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311C84 #6F841C
analogous
#1C3B84 #311C84 #651C84
triadic
#311C84 #84311C #1C8431
tetradic
#311C84 #841C3B #6F841C #1C8465
square
#311C84 #841C3B #6F841C #1C8465
split-complementary
#311C84 #84651C #3B841C
monochromatic
#0C071F #1E1152 #311C84 #4427B6 #6143D7

Accessibility & contrast

On white

12.89
#311C84 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.63
#311C84 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311C84
12.89:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311C84#FFFFFF#000000##FFFFFF
##311C841.0012.891.6312.89
#FFFFFF12.891.0021.001.00
#0000001.6321.001.0021.00
##FFFFFF12.891.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003587
Deuteranopia (green-blind)
#002E82
Tritanopia (blue-blind)
#003A4F
Achromatopsia (no color)
#323232

Design tokens & code

CSS
--color: #311c84;
/* rgb */ color: rgb(49, 28, 132);
/* oklch */ color: oklch(33.3% 0.161 282.5);
Tailwind
colors: {
  custom: {
    50: '#755ba9',
    500: '#311c84',
    950: '#000000',
  },
}
SCSS
$custom: #311c84;
$custom-light: #755ba9;
$custom-dark: #000000;
JSON
{
  "hex": "#311c84",
  "rgb": {
    "r": 49,
    "g": 28,
    "b": 132
  },
  "hsl": {
    "h": 252.115,
    "s": 65,
    "l": 31.373
  },
  "oklch": {
    "l": 0.33335,
    "c": 0.16078,
    "h": 282.5
  },
  "luminance": 0.03149
}

Semantic roles & 50–950 ramp

primary
#311C84
secondary
#A0B745
accent
#E840C6
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#090410
muted
#7B797F

Preview Lab

Preview with #311C84

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

Preview Lab → · Contrast checker → · Palette generator →

#311C84 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva