#311E81#311E81

#311E81 is a dark, vivid violet. Relative luminance 0.032; OKLCH L 33.3% C 0.155 H 282.8°. Best body text is #FFFFFF at 12.86:1 contrast (WCAG AA passes).

Color values

HEX#311E81
RGBrgb(49, 30, 129)
HSLhsl(252, 62%, 31%)
HSVhsv(252, 77%, 51%)
CMYKcmyk(62%, 76.7%, 0%, 49.4%)
CIE-LABlab(20.70, 37.44, -52.42)
CIE-LCHlch(20.70, 64.42, 305.54°)
OKLaboklab(33.29% 0.0343 -0.1511)
OKLCHoklch(33.29% 0.155 282.8)
XYZxyz(5.6921, 3.1661, 21.0758)
Luminance0.0317 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311E81 #6E811E
analogous
#1E3C81 #311E81 #621E81
triadic
#311E81 #81311E #1E8131
tetradic
#311E81 #811E3C #6E811E #1E8162
square
#311E81 #811E3C #6E811E #1E8162
split-complementary
#311E81 #81621E #3C811E
monochromatic
#0B071E #1E124F #311E81 #442AB3 #6146D4

Accessibility & contrast

On white

12.86
#311E81 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #311E81
12.86:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311E81#FFFFFF#000000##FFFFFF
##311E811.0012.861.6312.86
#FFFFFF12.861.0021.001.00
#0000001.6321.001.0021.00
##FFFFFF12.861.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003584
Deuteranopia (green-blind)
#002E7F
Tritanopia (blue-blind)
#003A4E
Achromatopsia (no color)
#323232

Design tokens & code

CSS
--color: #311e81;
/* rgb */ color: rgb(49, 30, 129);
/* oklch */ color: oklch(33.3% 0.155 282.8);
Tailwind
colors: {
  custom: {
    50: '#745ca7',
    500: '#311e81',
    950: '#000000',
  },
}
SCSS
$custom: #311e81;
$custom-light: #745ca7;
$custom-dark: #000000;
JSON
{
  "hex": "#311e81",
  "rgb": {
    "r": 49,
    "g": 30,
    "b": 129
  },
  "hsl": {
    "h": 251.515,
    "s": 62.264,
    "l": 31.176
  },
  "oklch": {
    "l": 0.33287,
    "c": 0.15496,
    "h": 282.8
  },
  "luminance": 0.03166
}

Semantic roles & 50–950 ramp

primary
#311E81
secondary
#9FB447
accent
#E542C6
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09040F
muted
#7B797F

Preview Lab

Preview with #311E81

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

Preview Lab → · Contrast checker → · Palette generator →

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