#311A8D#311A8D

#311A8D is a dark, vivid violet. Relative luminance 0.033; OKLCH L 34.1% C 0.174 H 281.1°. Best body text is #FFFFFF at 12.63:1 contrast (WCAG AA passes).

Color values

HEX#311A8D
RGBrgb(49, 26, 141)
HSLhsl(252, 69%, 33%)
HSVhsv(252, 82%, 55%)
CMYKcmyk(65.2%, 81.6%, 0%, 44.7%)
CIE-LABlab(21.26, 43.25, -59.03)
CIE-LCHlch(21.26, 73.18, 306.23°)
OKLaboklab(34.07% 0.0335 -0.1703)
OKLCHoklch(34.07% 0.174 281.1)
XYZxyz(6.4422, 3.3144, 25.4944)
Luminance0.0331 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311A8D #768D1A
analogous
#1A3C8D #311A8D #6A1A8D
triadic
#311A8D #8D311A #1A8D31
tetradic
#311A8D #8D1A3C #768D1A #1A8D6A
square
#311A8D #8D1A3C #768D1A #1A8D6A
split-complementary
#311A8D #8D6A1A #3C8D1A
monochromatic
#0D0726 #1F1059 #311A8D #4324C1 #6345DD

Accessibility & contrast

On white

12.63
#311A8D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.66
#311A8D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311A8D
12.63:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311A8D#FFFFFF#000000##FFFFFF
##311A8D1.0012.631.6612.63
#FFFFFF12.631.0021.001.00
#0000001.6621.001.0021.00
##FFFFFF12.631.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003790
Deuteranopia (green-blind)
#002F8B
Tritanopia (blue-blind)
#003D54
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #311a8d;
/* rgb */ color: rgb(49, 26, 141);
/* oklch */ color: oklch(34.1% 0.174 281.1);
Tailwind
colors: {
  custom: {
    50: '#775bb0',
    500: '#311a8d',
    950: '#000000',
  },
}
SCSS
$custom: #311a8d;
$custom-light: #775bb0;
$custom-dark: #000000;
JSON
{
  "hex": "#311a8d",
  "rgb": {
    "r": 49,
    "g": 26,
    "b": 141
  },
  "hsl": {
    "h": 252,
    "s": 68.862,
    "l": 32.745
  },
  "oklch": {
    "l": 0.34066,
    "c": 0.1736,
    "h": 281.1
  },
  "luminance": 0.03315
}

Semantic roles & 50–950 ramp

primary
#311A8D
secondary
#A6BE45
accent
#EC3CC9
background
#F7F5FA
surface
#EEE9F5
border
#C9C5CF
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #311A8D

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

Preview Lab → · Contrast checker → · Palette generator →

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