#311C8E#311C8E

#311C8E is a dark, vivid violet. Relative luminance 0.034; OKLCH L 34.4% C 0.173 H 280.7°. Best body text is #FFFFFF at 12.45:1 contrast (WCAG AA passes).

Color values

HEX#311C8E
RGBrgb(49, 28, 142)
HSLhsl(251, 67%, 33%)
HSVhsv(251, 80%, 56%)
CMYKcmyk(65.5%, 80.3%, 0%, 44.3%)
CIE-LABlab(21.71, 42.58, -58.91)
CIE-LCHlch(21.71, 72.68, 305.86°)
OKLaboklab(34.41% 0.032 -0.17)
OKLCHoklch(34.41% 0.173 280.7)
XYZxyz(6.5628, 3.4360, 25.9033)
Luminance0.0344 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311C8E #798E1C
analogous
#1C408E #311C8E #6A1C8E
triadic
#311C8E #8E311C #1C8E31
tetradic
#311C8E #8E1C40 #798E1C #1C8E6A
square
#311C8E #8E1C40 #798E1C #1C8E6A
split-complementary
#311C8E #8E6A1C #408E1C
monochromatic
#0E0828 #1F125B #311C8E #4326C1 #6449DB

Accessibility & contrast

On white

12.45
#311C8E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.69
#311C8E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311C8E
12.45:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311C8E#FFFFFF#000000##FFFFFF
##311C8E1.0012.451.6912.45
#FFFFFF12.451.0021.001.00
#0000001.6921.001.0021.00
##FFFFFF12.451.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003891
Deuteranopia (green-blind)
#00308C
Tritanopia (blue-blind)
#003E55
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #311c8e;
/* rgb */ color: rgb(49, 28, 142);
/* oklch */ color: oklch(34.4% 0.173 280.7);
Tailwind
colors: {
  custom: {
    50: '#775cb0',
    500: '#311c8e',
    950: '#000000',
  },
}
SCSS
$custom: #311c8e;
$custom-light: #775cb0;
$custom-dark: #000000;
JSON
{
  "hex": "#311c8e",
  "rgb": {
    "r": 49,
    "g": 28,
    "b": 142
  },
  "hsl": {
    "h": 251.053,
    "s": 67.059,
    "l": 33.333
  },
  "oklch": {
    "l": 0.34412,
    "c": 0.173,
    "h": 280.7
  },
  "luminance": 0.03436
}

Semantic roles & 50–950 ramp

primary
#311C8E
secondary
#A8BD49
accent
#EA3ECA
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #311C8E

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

Preview Lab → · Contrast checker → · Palette generator →

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