#311B97#311B97

#311B97 is a dark, vivid violet. Relative luminance 0.037; OKLCH L 35.3% C 0.185 H 279.3°. Best body text is #FFFFFF at 12.11:1 contrast (WCAG AA passes).

Color values

HEX#311B97
RGBrgb(49, 27, 151)
HSLhsl(251, 70%, 35%)
HSVhsv(251, 82%, 59%)
CMYKcmyk(67.5%, 82.1%, 0%, 40.8%)
CIE-LABlab(22.55, 45.81, -63.09)
CIE-LCHlch(22.55, 77.97, 305.98°)
OKLaboklab(35.29% 0.0298 -0.1822)
OKLCHoklch(35.29% 0.185 279.3)
XYZxyz(7.2427, 3.6706, 29.5990)
Luminance0.0367 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311B97 #81971B
analogous
#1B4397 #311B97 #6F1B97
triadic
#311B97 #97311B #1B9731
tetradic
#311B97 #971B43 #81971B #1B976F
square
#311B97 #971B43 #81971B #1B976F
split-complementary
#311B97 #976F1B #43971B
monochromatic
#0F082F #201263 #311B97 #4224CB #674DDF

Accessibility & contrast

On white

12.11
#311B97 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.73
#311B97 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311B97
12.11:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311B97#FFFFFF#000000##FFFFFF
##311B971.0012.111.7312.11
#FFFFFF12.111.0021.001.00
#0000001.7321.001.0021.00
##FFFFFF12.111.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A9A
Deuteranopia (green-blind)
#003195
Tritanopia (blue-blind)
#00415A
Achromatopsia (no color)
#363636

Design tokens & code

CSS
--color: #311b97;
/* rgb */ color: rgb(49, 27, 151);
/* oklch */ color: oklch(35.3% 0.185 279.3);
Tailwind
colors: {
  custom: {
    50: '#795cb7',
    500: '#311b97',
    950: '#000000',
  },
}
SCSS
$custom: #311b97;
$custom-light: #795cb7;
$custom-dark: #000000;
JSON
{
  "hex": "#311b97",
  "rgb": {
    "r": 49,
    "g": 27,
    "b": 151
  },
  "hsl": {
    "h": 250.645,
    "s": 69.663,
    "l": 34.902
  },
  "oklch": {
    "l": 0.35292,
    "c": 0.18461,
    "h": 279.3
  },
  "luminance": 0.03671
}

Semantic roles & 50–950 ramp

primary
#311B97
secondary
#ADC14C
accent
#EC3BCD
background
#F8F5FB
surface
#EFE9F6
border
#CAC5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #311B97

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

Preview Lab → · Contrast checker → · Palette generator →

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