#31166B#31166B

#31166B is a dark, vivid violet. Relative luminance 0.023; OKLCH L 30.0% C 0.136 H 290.1°. Best body text is #FFFFFF at 14.41:1 contrast (WCAG AA passes).

Color values

HEX#31166B
RGBrgb(49, 22, 107)
HSLhsl(259, 66%, 25%)
HSVhsv(259, 79%, 42%)
CMYKcmyk(54.2%, 79.4%, 0%, 58%)
CIE-LABlab(16.93, 34.91, -44.47)
CIE-LCHlch(16.93, 56.54, 308.14°)
OKLaboklab(29.96% 0.0468 -0.1278)
OKLCHoklch(29.96% 0.136 290.1)
XYZxyz(4.2066, 2.2881, 14.1271)
Luminance0.0229 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31166B #506B16
analogous
#16256B #31166B #5B166B
triadic
#31166B #6B3116 #166B31
tetradic
#31166B #6B1625 #506B16 #166B5B
square
#31166B #6B1625 #506B16 #166B5B
split-complementary
#31166B #6B5B16 #256B16
monochromatic
#0C0519 #1A0C38 #31166B #48209E #5F2BD1

Accessibility & contrast

On white

14.41
#31166B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.46
#31166B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31166B
14.41:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31166B#FFFFFF#000000##FFFFFF
##31166B1.0014.411.4614.41
#FFFFFF14.411.0021.001.00
#0000001.4621.001.0021.00
##FFFFFF14.411.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002B6D
Deuteranopia (green-blind)
#002869
Tritanopia (blue-blind)
#1C2D3F
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #31166b;
/* rgb */ color: rgb(49, 22, 107);
/* oklch */ color: oklch(30.0% 0.136 290.1);
Tailwind
colors: {
  custom: {
    50: '#705696',
    500: '#31166b',
    950: '#000000',
  },
}
SCSS
$custom: #31166b;
$custom-light: #705696;
$custom-dark: #000000;
JSON
{
  "hex": "#31166b",
  "rgb": {
    "r": 49,
    "g": 22,
    "b": 107
  },
  "hsl": {
    "h": 259.059,
    "s": 65.891,
    "l": 25.294
  },
  "oklch": {
    "l": 0.29957,
    "c": 0.13608,
    "h": 290.1
  },
  "luminance": 0.02288
}

Semantic roles & 50–950 ramp

primary
#31166B
secondary
#81A13B
accent
#E93FB3
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030D
muted
#7B787E

Preview Lab

Preview with #31166B

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

Preview Lab → · Contrast checker → · Palette generator →

#31166B Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva