#311D78#311D78

#311D78 is a dark, vivid violet. Relative luminance 0.029; OKLCH L 32.2% C 0.145 H 285.0°. Best body text is #FFFFFF at 13.31:1 contrast (WCAG AA passes).

Color values

HEX#311D78
RGBrgb(49, 29, 120)
HSLhsl(253, 61%, 29%)
HSVhsv(253, 76%, 47%)
CMYKcmyk(59.2%, 75.8%, 0%, 52.9%)
CIE-LABlab(19.59, 35.13, -48.52)
CIE-LCHlch(19.59, 59.90, 305.91°)
OKLaboklab(32.23% 0.0374 -0.1397)
OKLCHoklch(32.23% 0.145 285)
XYZxyz(5.0951, 2.8875, 18.0545)
Luminance0.0289 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311D78 #64781D
analogous
#1D3778 #311D78 #5F1D78
triadic
#311D78 #78311D #1D7831
tetradic
#311D78 #781D37 #64781D #1D785F
square
#311D78 #781D37 #64781D #1D785F
split-complementary
#311D78 #785F1D #37781D
monochromatic
#0A0619 #1D1147 #311D78 #4529A9 #5F3FD1

Accessibility & contrast

On white

13.31
#311D78 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.58
#311D78 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311D78
13.31:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311D78#FFFFFF#000000##FFFFFF
##311D781.0013.311.5813.31
#FFFFFF13.311.0021.001.00
#0000001.5821.001.0021.00
##FFFFFF13.311.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00327B
Deuteranopia (green-blind)
#002D76
Tritanopia (blue-blind)
#0D3649
Achromatopsia (no color)
#2F2F2F

Design tokens & code

CSS
--color: #311d78;
/* rgb */ color: rgb(49, 29, 120);
/* oklch */ color: oklch(32.2% 0.145 285.0);
Tailwind
colors: {
  custom: {
    50: '#725ba0',
    500: '#311d78',
    950: '#000000',
  },
}
SCSS
$custom: #311d78;
$custom-light: #725ba0;
$custom-dark: #000000;
JSON
{
  "hex": "#311d78",
  "rgb": {
    "r": 49,
    "g": 29,
    "b": 120
  },
  "hsl": {
    "h": 253.187,
    "s": 61.074,
    "l": 29.216
  },
  "oklch": {
    "l": 0.32226,
    "c": 0.1446,
    "h": 285
  },
  "luminance": 0.02888
}

Semantic roles & 50–950 ramp

primary
#311D78
secondary
#95AC45
accent
#E444C1
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#09040F
muted
#7B797E

Preview Lab

Preview with #311D78

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

Preview Lab → · Contrast checker → · Palette generator →

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