#31154B#31154B

#31154B is a dark, moderate violet. Relative luminance 0.017; OKLCH L 26.8% C 0.097 H 304.5°. Best body text is #FFFFFF at 15.68:1 contrast (WCAG AA passes).

Color values

HEX#31154B
RGBrgb(49, 21, 75)
HSLhsl(271, 56%, 19%)
HSVhsv(271, 72%, 29%)
CMYKcmyk(34.7%, 72%, 0%, 70.6%)
CIE-LABlab(13.81, 26.01, -28.09)
CIE-LCHlch(13.81, 38.28, 312.80°)
OKLaboklab(26.83% 0.0547 -0.0797)
OKLCHoklch(26.83% 0.097 304.5)
XYZxyz(2.8045, 1.6973, 6.8351)
Luminance0.0170 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31154B #2F4B15
analogous
#16154B #31154B #4B154A
triadic
#31154B #4B3115 #154B31
tetradic
#31154B #4B1615 #2F4B15 #154A4B
square
#31154B #4B1615 #2F4B15 #154A4B
split-complementary
#31154B #4A4B15 #154B16
monochromatic
#100718 #12081B #31154B #50227B #6F30AB

Accessibility & contrast

On white

15.68
#31154B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.34
#31154B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31154B
15.68:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31154B#FFFFFF#000000##FFFFFF
##31154B1.0015.681.3415.68
#FFFFFF15.681.0021.001.00
#0000001.3421.001.0021.00
##FFFFFF15.681.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00224D
Deuteranopia (green-blind)
#06234A
Tritanopia (blue-blind)
#2C212D
Achromatopsia (no color)
#232323

Design tokens & code

CSS
--color: #31154b;
/* rgb */ color: rgb(49, 21, 75);
/* oklch */ color: oklch(26.8% 0.097 304.5);
Tailwind
colors: {
  custom: {
    50: '#6c547e',
    500: '#31154b',
    950: '#000000',
  },
}
SCSS
$custom: #31154b;
$custom-light: #6c547e;
$custom-dark: #000000;
JSON
{
  "hex": "#31154b",
  "rgb": {
    "r": 49,
    "g": 21,
    "b": 75
  },
  "hsl": {
    "h": 271.111,
    "s": 56.25,
    "l": 18.824
  },
  "oklch": {
    "l": 0.26832,
    "c": 0.09663,
    "h": 304.5
  },
  "luminance": 0.01697
}

Semantic roles & 50–950 ramp

primary
#31154B
secondary
#5D8339
accent
#E04891
background
#F6F4F7
surface
#EBE8EE
border
#C6C4C9
text
#07030A
muted
#7A787C

Preview Lab

Preview with #31154B

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

Preview Lab → · Contrast checker → · Palette generator →

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