#31175B#31175B

#31175B is a dark, moderate violet. Relative luminance 0.020; OKLCH L 28.5% C 0.115 H 295.8°. Best body text is #FFFFFF at 14.96:1 contrast (WCAG AA passes).

Color values

HEX#31175B
RGBrgb(49, 23, 91)
HSLhsl(263, 60%, 22%)
HSVhsv(263, 75%, 36%)
CMYKcmyk(46.2%, 74.7%, 0%, 64.3%)
CIE-LABlab(15.60, 29.53, -36.07)
CIE-LCHlch(15.60, 46.61, 309.31°)
OKLaboklab(28.54% 0.0498 -0.1031)
OKLCHoklch(28.54% 0.115 295.8)
XYZxyz(3.4608, 2.0210, 10.1033)
Luminance0.0202 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31175B #415B17
analogous
#171F5B #31175B #53175B
triadic
#31175B #5B3117 #175B31
tetradic
#31175B #5B171F #415B17 #175B53
square
#31175B #5B171F #415B17 #175B53
split-complementary
#31175B #5B5317 #1F5B17
monochromatic
#0D0618 #170B2A #31175B #4B238C #6630BD

Accessibility & contrast

On white

14.96
#31175B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.40
#31175B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31175B
14.96:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31175B#FFFFFF#000000##FFFFFF
##31175B1.0014.961.4014.96
#FFFFFF14.961.0021.001.00
#0000001.4021.001.0021.00
##FFFFFF14.961.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00275D
Deuteranopia (green-blind)
#00265A
Tritanopia (blue-blind)
#262837
Achromatopsia (no color)
#272727

Design tokens & code

CSS
--color: #31175b;
/* rgb */ color: rgb(49, 23, 91);
/* oklch */ color: oklch(28.5% 0.115 295.8);
Tailwind
colors: {
  custom: {
    50: '#6e568a',
    500: '#31175b',
    950: '#000000',
  },
}
SCSS
$custom: #31175b;
$custom-light: #6e568a;
$custom-dark: #000000;
JSON
{
  "hex": "#31175b",
  "rgb": {
    "r": 49,
    "g": 23,
    "b": 91
  },
  "hsl": {
    "h": 262.941,
    "s": 59.649,
    "l": 22.353
  },
  "oklch": {
    "l": 0.28541,
    "c": 0.11452,
    "h": 295.8
  },
  "luminance": 0.02021
}

Semantic roles & 50–950 ramp

primary
#31175B
secondary
#71923C
accent
#E345A6
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#07030C
muted
#7A787D

Preview Lab

Preview with #31175B

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

Preview Lab → · Contrast checker → · Palette generator →

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