#311E78#311E78

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

Color values

HEX#311E78
RGBrgb(49, 30, 120)
HSLhsl(253, 60%, 29%)
HSVhsv(253, 75%, 47%)
CMYKcmyk(59.2%, 75%, 0%, 52.9%)
CIE-LABlab(19.79, 34.56, -48.18)
CIE-LCHlch(19.79, 59.30, 305.65°)
OKLaboklab(32.37% 0.0365 -0.1387)
OKLCHoklch(32.37% 0.143 284.7)
XYZxyz(5.1200, 2.9373, 18.0628)
Luminance0.0294 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311E78 #65781E
analogous
#1E3878 #311E78 #5E1E78
triadic
#311E78 #78311E #1E7831
tetradic
#311E78 #781E38 #65781E #1E785E
square
#311E78 #781E38 #65781E #1E785E
split-complementary
#311E78 #785E1E #38781E
monochromatic
#0A0618 #1D1247 #311E78 #452AA9 #5F41CF

Accessibility & contrast

On white

13.23
#311E78 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.59
#311E78 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311E78
13.23:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311E78#FFFFFF#000000##FFFFFF
##311E781.0013.231.5913.23
#FFFFFF13.231.0021.001.00
#0000001.5921.001.0021.00
##FFFFFF13.231.0021.001.00

Color blindness preview

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

Design tokens & code

CSS
--color: #311e78;
/* rgb */ color: rgb(49, 30, 120);
/* oklch */ color: oklch(32.4% 0.143 284.7);
Tailwind
colors: {
  custom: {
    50: '#725ca0',
    500: '#311e78',
    950: '#000000',
  },
}
SCSS
$custom: #311e78;
$custom-light: #725ca0;
$custom-dark: #000000;
JSON
{
  "hex": "#311e78",
  "rgb": {
    "r": 49,
    "g": 30,
    "b": 120
  },
  "hsl": {
    "h": 252.667,
    "s": 60,
    "l": 29.412
  },
  "oklch": {
    "l": 0.32371,
    "c": 0.14344,
    "h": 284.7
  },
  "luminance": 0.02938
}

Semantic roles & 50–950 ramp

primary
#311E78
secondary
#96AC46
accent
#E345C2
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#09040F
muted
#7B797E

Preview Lab

Preview with #311E78

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

Preview Lab → · Contrast checker → · Palette generator →

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