#31177E#31177E

#31177E is a dark, vivid violet. Relative luminance 0.028; OKLCH L 32.1% C 0.158 H 284.7°. Best body text is #FFFFFF at 13.51:1 contrast (WCAG AA passes).

Color values

HEX#31177E
RGBrgb(49, 23, 126)
HSLhsl(255, 69%, 29%)
HSVhsv(255, 82%, 49%)
CMYKcmyk(61.1%, 81.7%, 0%, 50.6%)
CIE-LABlab(19.11, 40.16, -53.14)
CIE-LCHlch(19.11, 66.61, 307.08°)
OKLaboklab(32.08% 0.0401 -0.1531)
OKLCHoklch(32.08% 0.158 284.7)
XYZxyz(5.3378, 2.7718, 19.9884)
Luminance0.0277 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31177E #647E17
analogous
#17307E #31177E #65177E
triadic
#31177E #7E3117 #177E31
tetradic
#31177E #7E1730 #647E17 #177E65
square
#31177E #7E1730 #647E17 #177E65
split-complementary
#31177E #7E6517 #307E17
monochromatic
#0A051A #1D0E4A #31177E #4520B2 #5F35DA

Accessibility & contrast

On white

13.51
#31177E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.55
#31177E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31177E
13.51:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31177E#FFFFFF#000000##FFFFFF
##31177E1.0013.511.5513.51
#FFFFFF13.511.0021.001.00
#0000001.5521.001.0021.00
##FFFFFF13.511.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003181
Deuteranopia (green-blind)
#002B7C
Tritanopia (blue-blind)
#02364B
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #31177e;
/* rgb */ color: rgb(49, 23, 126);
/* oklch */ color: oklch(32.1% 0.158 284.7);
Tailwind
colors: {
  custom: {
    50: '#7458a4',
    500: '#31177e',
    950: '#000000',
  },
}
SCSS
$custom: #31177e;
$custom-light: #7458a4;
$custom-dark: #000000;
JSON
{
  "hex": "#31177e",
  "rgb": {
    "r": 49,
    "g": 23,
    "b": 126
  },
  "hsl": {
    "h": 255.146,
    "s": 69.128,
    "l": 29.216
  },
  "oklch": {
    "l": 0.32077,
    "c": 0.15831,
    "h": 284.7
  },
  "luminance": 0.02772
}

Semantic roles & 50–950 ramp

primary
#31177E
secondary
#95B33E
accent
#EC3CBF
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #31177E

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

Preview Lab → · Contrast checker → · Palette generator →

#31177E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva