#31174C#31174C

#31174C is a dark, moderate violet. Relative luminance 0.018; OKLCH L 27.2% C 0.095 H 303.2°. Best body text is #FFFFFF at 15.47:1 contrast (WCAG AA passes).

Color values

HEX#31174C
RGBrgb(49, 23, 76)
HSLhsl(269, 54%, 19%)
HSVhsv(269, 70%, 30%)
CMYKcmyk(35.5%, 69.7%, 0%, 70.2%)
CIE-LABlab(14.33, 25.09, -27.94)
CIE-LCHlch(14.33, 37.55, 311.93°)
OKLaboklab(27.23% 0.0519 -0.0792)
OKLCHoklch(27.23% 0.095 303.2)
XYZxyz(2.8772, 1.7876, 7.0295)
Luminance0.0179 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31174C #324C17
analogous
#17184C #31174C #4C174C
triadic
#31174C #4C3117 #174C31
tetradic
#31174C #4C1718 #324C17 #174C4C
square
#31174C #4C1718 #324C17 #174C4C
split-complementary
#31174C #4C4C17 #184C17
monochromatic
#0F0717 #13091D #31174C #4F257B #6E33AA

Accessibility & contrast

On white

15.47
#31174C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.36
#31174C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31174C
15.47:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31174C#FFFFFF#000000##FFFFFF
##31174C1.0015.471.3615.47
#FFFFFF15.471.0021.001.00
#0000001.3621.001.0021.00
##FFFFFF15.471.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00244E
Deuteranopia (green-blind)
#07244B
Tritanopia (blue-blind)
#2C222F
Achromatopsia (no color)
#242424

Design tokens & code

CSS
--color: #31174c;
/* rgb */ color: rgb(49, 23, 76);
/* oklch */ color: oklch(27.2% 0.095 303.2);
Tailwind
colors: {
  custom: {
    50: '#6c567e',
    500: '#31174c',
    950: '#000000',
  },
}
SCSS
$custom: #31174c;
$custom-light: #6c567e;
$custom-dark: #000000;
JSON
{
  "hex": "#31174c",
  "rgb": {
    "r": 49,
    "g": 23,
    "b": 76
  },
  "hsl": {
    "h": 269.434,
    "s": 53.535,
    "l": 19.412
  },
  "oklch": {
    "l": 0.27232,
    "c": 0.0947,
    "h": 303.2
  },
  "luminance": 0.01788
}

Semantic roles & 50–950 ramp

primary
#31174C
secondary
#60833C
accent
#DD4B95
background
#F6F5F7
surface
#EBE9EE
border
#C6C5C9
text
#07030A
muted
#7A787C

Preview Lab

Preview with #31174C

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

Preview Lab → · Contrast checker → · Palette generator →

#31174C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva