#31166F#31166F

#31166F is a dark, vivid violet. Relative luminance 0.024; OKLCH L 30.4% C 0.141 H 288.9°. Best body text is #FFFFFF at 14.24:1 contrast (WCAG AA passes).

Color values

HEX#31166F
RGBrgb(49, 22, 111)
HSLhsl(258, 67%, 26%)
HSVhsv(258, 80%, 44%)
CMYKcmyk(55.9%, 80.2%, 0%, 56.5%)
CIE-LABlab(17.34, 36.12, -46.41)
CIE-LCHlch(17.34, 58.81, 307.90°)
OKLaboklab(30.37% 0.0456 -0.1335)
OKLCHoklch(30.37% 0.141 288.9)
XYZxyz(4.4219, 2.3743, 15.2611)
Luminance0.0237 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31166F #546F16
analogous
#16276F #31166F #5D166F
triadic
#31166F #6F3116 #166F31
tetradic
#31166F #6F1627 #546F16 #166F5D
square
#31166F #6F1627 #546F16 #166F5D
split-complementary
#31166F #6F5D16 #276F16
monochromatic
#0B051A #1A0C3C #31166F #4820A2 #5E2BD5

Accessibility & contrast

On white

14.24
#31166F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.47
#31166F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31166F
14.24:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31166F#FFFFFF#000000##FFFFFF
##31166F1.0014.241.4714.24
#FFFFFF14.241.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.241.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002C72
Deuteranopia (green-blind)
#00286D
Tritanopia (blue-blind)
#192F42
Achromatopsia (no color)
#2B2B2B

Design tokens & code

CSS
--color: #31166f;
/* rgb */ color: rgb(49, 22, 111);
/* oklch */ color: oklch(30.4% 0.141 288.9);
Tailwind
colors: {
  custom: {
    50: '#715799',
    500: '#31166f',
    950: '#000000',
  },
}
SCSS
$custom: #31166f;
$custom-light: #715799;
$custom-dark: #000000;
JSON
{
  "hex": "#31166f",
  "rgb": {
    "r": 49,
    "g": 22,
    "b": 111
  },
  "hsl": {
    "h": 258.202,
    "s": 66.917,
    "l": 26.078
  },
  "oklch": {
    "l": 0.30367,
    "c": 0.14103,
    "h": 288.9
  },
  "luminance": 0.02374
}

Semantic roles & 50–950 ramp

primary
#31166F
secondary
#85A53C
accent
#EA3EB6
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #31166F

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

Preview Lab → · Contrast checker → · Palette generator →

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