#311678#311678

#311678 is a dark, vivid violet. Relative luminance 0.026; OKLCH L 31.3% C 0.152 H 286.3°. Best body text is #FFFFFF at 13.85:1 contrast (WCAG AA passes).

Color values

HEX#311678
RGBrgb(49, 22, 120)
HSLhsl(257, 69%, 28%)
HSVhsv(257, 82%, 47%)
CMYKcmyk(59.2%, 81.7%, 0%, 52.9%)
CIE-LABlab(18.29, 38.84, -50.66)
CIE-LCHlch(18.29, 63.83, 307.48°)
OKLaboklab(31.31% 0.0428 -0.1459)
OKLCHoklch(31.31% 0.152 286.3)
XYZxyz(4.9427, 2.5826, 18.0037)
Luminance0.0258 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311678 #5D7816
analogous
#162C78 #311678 #621678
triadic
#311678 #783116 #167831
tetradic
#311678 #78162C #5D7816 #167862
square
#311678 #78162C #5D7816 #167862
split-complementary
#311678 #786216 #2C7816
monochromatic
#0B051A #1C0D44 #311678 #461FAC #5E2FD9

Accessibility & contrast

On white

13.85
#311678 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.52
#311678 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311678
13.85:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311678#FFFFFF#000000##FFFFFF
##3116781.0013.851.5213.85
#FFFFFF13.851.0021.001.00
#0000001.5221.001.0021.00
##FFFFFF13.851.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002F7B
Deuteranopia (green-blind)
#002A76
Tritanopia (blue-blind)
#0E3347
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #311678;
/* rgb */ color: rgb(49, 22, 120);
/* oklch */ color: oklch(31.3% 0.152 286.3);
Tailwind
colors: {
  custom: {
    50: '#7357a0',
    500: '#311678',
    950: '#000000',
  },
}
SCSS
$custom: #311678;
$custom-light: #7357a0;
$custom-dark: #000000;
JSON
{
  "hex": "#311678",
  "rgb": {
    "r": 49,
    "g": 22,
    "b": 120
  },
  "hsl": {
    "h": 256.531,
    "s": 69.014,
    "l": 27.843
  },
  "oklch": {
    "l": 0.31314,
    "c": 0.15202,
    "h": 286.3
  },
  "luminance": 0.02583
}

Semantic roles & 50–950 ramp

primary
#311678
secondary
#8EAD3C
accent
#EC3CBB
background
#F7F5FA
surface
#EDE9F3
border
#C8C5CD
text
#09030F
muted
#7B787F

Preview Lab

Preview with #311678

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

Preview Lab → · Contrast checker → · Palette generator →

#311678 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva