#31124C#31124C

#31124C is a dark, moderate violet. Relative luminance 0.016; OKLCH L 26.5% C 0.103 H 304.8°. Best body text is #FFFFFF at 15.89:1 contrast (WCAG AA passes).

Color values

HEX#31124C
RGBrgb(49, 18, 76)
HSLhsl(272, 62%, 18%)
HSVhsv(272, 76%, 30%)
CMYKcmyk(35.5%, 76.3%, 0%, 70.2%)
CIE-LABlab(13.28, 28.00, -29.64)
CIE-LCHlch(13.28, 40.78, 313.37°)
OKLaboklab(26.47% 0.0585 -0.0842)
OKLCHoklch(26.47% 0.103 304.8)
XYZxyz(2.7871, 1.6074, 6.9995)
Luminance0.0161 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31124C #2D4C12
analogous
#14124C #31124C #4C124A
triadic
#31124C #4C3112 #124C31
tetradic
#31124C #4C1412 #2D4C12 #124A4C
square
#31124C #4C1412 #2D4C12 #124A4C
split-complementary
#31124C #4A4C12 #124C14
monochromatic
#100619 #11061B #31124C #511E7D #7129AF

Accessibility & contrast

On white

15.89
#31124C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.32
#31124C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31124C
15.89:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31124C#FFFFFF#000000##FFFFFF
##31124C1.0015.891.3215.89
#FFFFFF15.891.0021.001.00
#0000001.3221.001.0021.00
##FFFFFF15.891.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00214E
Deuteranopia (green-blind)
#00224B
Tritanopia (blue-blind)
#2C1F2D
Achromatopsia (no color)
#222222

Design tokens & code

CSS
--color: #31124c;
/* rgb */ color: rgb(49, 18, 76);
/* oklch */ color: oklch(26.5% 0.103 304.8);
Tailwind
colors: {
  custom: {
    50: '#6c537e',
    500: '#31124c',
    950: '#000000',
  },
}
SCSS
$custom: #31124c;
$custom-light: #6c537e;
$custom-dark: #000000;
JSON
{
  "hex": "#31124c",
  "rgb": {
    "r": 49,
    "g": 18,
    "b": 76
  },
  "hsl": {
    "h": 272.069,
    "s": 61.702,
    "l": 18.431
  },
  "oklch": {
    "l": 0.26473,
    "c": 0.10252,
    "h": 304.8
  },
  "luminance": 0.01607
}

Semantic roles & 50–950 ramp

primary
#31124C
secondary
#5A8535
accent
#E5438E
background
#F6F4F7
surface
#ECE7EE
border
#C7C3C9
text
#07020A
muted
#7A787C

Preview Lab

Preview with #31124C

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

Preview Lab → · Contrast checker → · Palette generator →

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