#31245D#31245D

#31245D is a dark, moderate violet. Relative luminance 0.027; OKLCH L 30.9% C 0.098 H 290.0°. Best body text is #FFFFFF at 13.63:1 contrast (WCAG AA passes).

Color values

HEX#31245D
RGBrgb(49, 36, 93)
HSLhsl(254, 44%, 25%)
HSVhsv(254, 61%, 36%)
CMYKcmyk(47.3%, 61.3%, 0%, 63.5%)
CIE-LABlab(18.82, 21.96, -32.18)
CIE-LCHlch(18.82, 38.96, 304.32°)
OKLaboklab(30.93% 0.0334 -0.0917)
OKLCHoklch(30.93% 0.098 290)
XYZxyz(3.8727, 2.7049, 10.6719)
Luminance0.0271 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31245D #505D24
analogous
#24335D #31245D #4D245D
triadic
#31245D #5D3124 #245D31
tetradic
#31245D #5D2433 #505D24 #245D4D
square
#31245D #5D2433 #505D24 #245D4D
split-complementary
#31245D #5D4D24 #335D24
monochromatic
#0C0916 #1A1331 #31245D #483589 #5F46B5

Accessibility & contrast

On white

13.63
#31245D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.54
#31245D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31245D
13.63:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31245D#FFFFFF#000000##FFFFFF
##31245D1.0013.631.5413.63
#FFFFFF13.631.0021.001.00
#0000001.5421.001.0021.00
##FFFFFF13.631.0021.001.00

Color blindness preview

Protanopia (red-blind)
#032F5F
Deuteranopia (green-blind)
#052C5C
Tritanopia (blue-blind)
#24313C
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #31245d;
/* rgb */ color: rgb(49, 36, 93);
/* oklch */ color: oklch(30.9% 0.098 290.0);
Tailwind
colors: {
  custom: {
    50: '#6d5f8b',
    500: '#31245d',
    950: '#000000',
  },
}
SCSS
$custom: #31245d;
$custom-light: #6d5f8b;
$custom-dark: #000000;
JSON
{
  "hex": "#31245d",
  "rgb": {
    "r": 49,
    "g": 36,
    "b": 93
  },
  "hsl": {
    "h": 253.684,
    "s": 44.186,
    "l": 25.294
  },
  "oklch": {
    "l": 0.30933,
    "c": 0.09758,
    "h": 290
  },
  "luminance": 0.02705
}

Semantic roles & 50–950 ramp

primary
#31245D
secondary
#81914C
accent
#D454B7
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#07040C
muted
#7A797D

Preview Lab

Preview with #31245D

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

Preview Lab → · Contrast checker → · Palette generator →

#31245D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva