#311F85#311F85

#311F85 is a dark, vivid violet. Relative luminance 0.033; OKLCH L 33.8% C 0.159 H 281.8°. Best body text is #FFFFFF at 12.61:1 contrast (WCAG AA passes).

Color values

HEX#311F85
RGBrgb(49, 31, 133)
HSLhsl(251, 62%, 32%)
HSVhsv(251, 77%, 52%)
CMYKcmyk(63.2%, 76.7%, 0%, 47.8%)
CIE-LABlab(21.30, 38.17, -53.94)
CIE-LCHlch(21.30, 66.08, 305.28°)
OKLaboklab(33.84% 0.0326 -0.1556)
OKLCHoklch(33.84% 0.159 281.8)
XYZxyz(5.9889, 3.3260, 22.5121)
Luminance0.0333 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311F85 #73851F
analogous
#1F4085 #311F85 #641F85
triadic
#311F85 #85311F #1F8531
tetradic
#311F85 #851F40 #73851F #1F8564
square
#311F85 #851F40 #73851F #1F8564
split-complementary
#311F85 #85641F #40851F
monochromatic
#0C0822 #1F1353 #311F85 #432BB7 #624AD5

Accessibility & contrast

On white

12.61
#311F85 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.67
#311F85 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311F85
12.61:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311F85#FFFFFF#000000##FFFFFF
##311F851.0012.611.6712.61
#FFFFFF12.611.0021.001.00
#0000001.6721.001.0021.00
##FFFFFF12.611.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003788
Deuteranopia (green-blind)
#002F83
Tritanopia (blue-blind)
#003C50
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #311f85;
/* rgb */ color: rgb(49, 31, 133);
/* oklch */ color: oklch(33.8% 0.159 281.8);
Tailwind
colors: {
  custom: {
    50: '#755daa',
    500: '#311f85',
    950: '#000000',
  },
}
SCSS
$custom: #311f85;
$custom-light: #755daa;
$custom-dark: #000000;
JSON
{
  "hex": "#311f85",
  "rgb": {
    "r": 49,
    "g": 31,
    "b": 133
  },
  "hsl": {
    "h": 250.588,
    "s": 62.195,
    "l": 32.157
  },
  "oklch": {
    "l": 0.3384,
    "c": 0.15894,
    "h": 281.8
  },
  "luminance": 0.03326
}

Semantic roles & 50–950 ramp

primary
#311F85
secondary
#A4B749
accent
#E543C9
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#090410
muted
#7B797F

Preview Lab

Preview with #311F85

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

Preview Lab → · Contrast checker → · Palette generator →

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