#31207F#31207F

#31207F is a dark, vivid violet. Relative luminance 0.032; OKLCH L 33.4% C 0.150 H 282.8°. Best body text is #FFFFFF at 12.78:1 contrast (WCAG AA passes).

Color values

HEX#31207F
RGBrgb(49, 32, 127)
HSLhsl(251, 60%, 31%)
HSVhsv(251, 75%, 50%)
CMYKcmyk(61.4%, 74.8%, 0%, 50.2%)
CIE-LABlab(20.90, 35.67, -50.83)
CIE-LCHlch(20.90, 62.10, 305.06°)
OKLaboklab(33.37% 0.0333 -0.1465)
OKLCHoklch(33.37% 0.15 282.8)
XYZxyz(5.6127, 3.2179, 20.3999)
Luminance0.0322 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31207F #6E7F20
analogous
#203E7F #31207F #60207F
triadic
#31207F #7F3120 #207F31
tetradic
#31207F #7F203E #6E7F20 #207F60
square
#31207F #7F203E #6E7F20 #207F60
split-complementary
#31207F #7F6020 #3E7F20
monochromatic
#0B071D #1E144E #31207F #442CB0 #6148D1

Accessibility & contrast

On white

12.78
#31207F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.64
#31207F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31207F
12.78:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31207F#FFFFFF#000000##FFFFFF
##31207F1.0012.781.6412.78
#FFFFFF12.781.0021.001.00
#0000001.6421.001.0021.00
##FFFFFF12.781.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003582
Deuteranopia (green-blind)
#002F7D
Tritanopia (blue-blind)
#003A4D
Achromatopsia (no color)
#323232

Design tokens & code

CSS
--color: #31207f;
/* rgb */ color: rgb(49, 32, 127);
/* oklch */ color: oklch(33.4% 0.150 282.8);
Tailwind
colors: {
  custom: {
    50: '#735da5',
    500: '#31207f',
    950: '#000000',
  },
}
SCSS
$custom: #31207f;
$custom-light: #735da5;
$custom-dark: #000000;
JSON
{
  "hex": "#31207f",
  "rgb": {
    "r": 49,
    "g": 32,
    "b": 127
  },
  "hsl": {
    "h": 250.737,
    "s": 59.748,
    "l": 31.176
  },
  "oklch": {
    "l": 0.33366,
    "c": 0.15019,
    "h": 282.8
  },
  "luminance": 0.03218
}

Semantic roles & 50–950 ramp

primary
#31207F
secondary
#9FB249
accent
#E345C7
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09040F
muted
#7B797F

Preview Lab

Preview with #31207F

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

Preview Lab → · Contrast checker → · Palette generator →

#31207F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva