#311D79#311D79

#311D79 is a dark, vivid violet. Relative luminance 0.029; OKLCH L 32.3% C 0.146 H 284.7°. Best body text is #FFFFFF at 13.27:1 contrast (WCAG AA passes).

Color values

HEX#311D79
RGBrgb(49, 29, 121)
HSLhsl(253, 61%, 29%)
HSVhsv(253, 76%, 47%)
CMYKcmyk(59.5%, 76%, 0%, 52.5%)
CIE-LABlab(19.69, 35.45, -48.99)
CIE-LCHlch(19.69, 60.48, 305.89°)
OKLaboklab(32.33% 0.0371 -0.1411)
OKLCHoklch(32.33% 0.146 284.7)
XYZxyz(5.1561, 2.9119, 18.3758)
Luminance0.0291 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311D79 #65791D
analogous
#1D3779 #311D79 #5F1D79
triadic
#311D79 #79311D #1D7931
tetradic
#311D79 #791D37 #65791D #1D795F
square
#311D79 #791D37 #65791D #1D795F
split-complementary
#311D79 #795F1D #37791D
monochromatic
#0A0619 #1D1148 #311D79 #4529AA #5F3FD1

Accessibility & contrast

On white

13.27
#311D79 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #311D79
13.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311D79#FFFFFF#000000##FFFFFF
##311D791.0013.271.5813.27
#FFFFFF13.271.0021.001.00
#0000001.5821.001.0021.00
##FFFFFF13.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00327C
Deuteranopia (green-blind)
#002D77
Tritanopia (blue-blind)
#0B3649
Achromatopsia (no color)
#303030

Design tokens & code

CSS
--color: #311d79;
/* rgb */ color: rgb(49, 29, 121);
/* oklch */ color: oklch(32.3% 0.146 284.7);
Tailwind
colors: {
  custom: {
    50: '#725ba1',
    500: '#311d79',
    950: '#000000',
  },
}
SCSS
$custom: #311d79;
$custom-light: #725ba1;
$custom-dark: #000000;
JSON
{
  "hex": "#311d79",
  "rgb": {
    "r": 49,
    "g": 29,
    "b": 121
  },
  "hsl": {
    "h": 253.043,
    "s": 61.333,
    "l": 29.412
  },
  "oklch": {
    "l": 0.32328,
    "c": 0.14588,
    "h": 284.7
  },
  "luminance": 0.02912
}

Semantic roles & 50–950 ramp

primary
#311D79
secondary
#96AD45
accent
#E443C1
background
#F7F5FA
surface
#EDE9F3
border
#C8C5CD
text
#09040F
muted
#7B797F

Preview Lab

Preview with #311D79

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

Preview Lab → · Contrast checker → · Palette generator →

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