#31196C#31196C

#31196C is a dark, vivid violet. Relative luminance 0.024; OKLCH L 30.5% C 0.134 H 289.1°. Best body text is #FFFFFF at 14.13:1 contrast (WCAG AA passes).

Color values

HEX#31196C
RGBrgb(49, 25, 108)
HSLhsl(257, 62%, 26%)
HSVhsv(257, 77%, 42%)
CMYKcmyk(54.6%, 76.9%, 0%, 57.6%)
CIE-LABlab(17.60, 33.60, -44.02)
CIE-LCHlch(17.60, 55.38, 307.35°)
OKLaboklab(30.46% 0.0439 -0.1265)
OKLCHoklch(30.46% 0.134 289.1)
XYZxyz(4.3202, 2.4307, 14.4260)
Luminance0.0243 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31196C #546C19
analogous
#192A6C #31196C #5A196C
triadic
#31196C #6C3119 #196C31
tetradic
#31196C #6C192A #546C19 #196C5A
square
#31196C #6C192A #546C19 #196C5A
split-complementary
#31196C #6C5A19 #2A6C19
monochromatic
#0B0619 #1A0D3A #31196C #48259E #5E30CF

Accessibility & contrast

On white

14.13
#31196C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.49
#31196C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31196C
14.13:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31196C#FFFFFF#000000##FFFFFF
##31196C1.0014.131.4914.13
#FFFFFF14.131.0021.001.00
#0000001.4921.001.0021.00
##FFFFFF14.131.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002D6E
Deuteranopia (green-blind)
#00296A
Tritanopia (blue-blind)
#1B2F41
Achromatopsia (no color)
#2B2B2B

Design tokens & code

CSS
--color: #31196c;
/* rgb */ color: rgb(49, 25, 108);
/* oklch */ color: oklch(30.5% 0.134 289.1);
Tailwind
colors: {
  custom: {
    50: '#705897',
    500: '#31196c',
    950: '#000000',
  },
}
SCSS
$custom: #31196c;
$custom-light: #705897;
$custom-dark: #000000;
JSON
{
  "hex": "#31196c",
  "rgb": {
    "r": 49,
    "g": 25,
    "b": 108
  },
  "hsl": {
    "h": 257.349,
    "s": 62.406,
    "l": 26.078
  },
  "oklch": {
    "l": 0.3046,
    "c": 0.13388,
    "h": 289.1
  },
  "luminance": 0.02431
}

Semantic roles & 50–950 ramp

primary
#31196C
secondary
#85A13F
accent
#E542B6
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030D
muted
#7B787E

Preview Lab

Preview with #31196C

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

Preview Lab → · Contrast checker → · Palette generator →

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