#331A4A#331A4A

#331A4A is a dark, moderate violet. Relative luminance 0.019; OKLCH L 27.8% C 0.087 H 305.5°. Best body text is #FFFFFF at 15.14:1 contrast (WCAG AA passes).

Color values

HEX#331A4A
RGBrgb(51, 26, 74)
HSLhsl(271, 48%, 20%)
HSVhsv(271, 65%, 29%)
CMYKcmyk(31.1%, 64.9%, 0%, 71%)
CIE-LABlab(15.15, 23.21, -25.23)
CIE-LCHlch(15.15, 34.28, 312.62°)
OKLaboklab(27.85% 0.0507 -0.0712)
OKLCHoklch(27.85% 0.087 305.5)
XYZxyz(2.9704, 1.9370, 6.6946)
Luminance0.0194 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331A4A #314A1A
analogous
#1B1A4A #331A4A #4A1A49
triadic
#331A4A #4A331A #1A4A33
tetradic
#331A4A #4A1B1A #314A1A #1A494A
square
#331A4A #4A1B1A #314A1A #1A494A
split-complementary
#331A4A #494A1A #1A4A1B
monochromatic
#100817 #140A1D #331A4A #522A77 #713AA5

Accessibility & contrast

On white

15.14
#331A4A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.39
#331A4A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331A4A
15.14:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331A4A#FFFFFF#000000##FFFFFF
##331A4A1.0015.141.3915.14
#FFFFFF15.141.0021.001.00
#0000001.3921.001.0021.00
##FFFFFF15.141.0021.001.00

Color blindness preview

Protanopia (red-blind)
#06254C
Deuteranopia (green-blind)
#112649
Tritanopia (blue-blind)
#2F232F
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #331a4a;
/* rgb */ color: rgb(51, 26, 74);
/* oklch */ color: oklch(27.8% 0.087 305.5);
Tailwind
colors: {
  custom: {
    50: '#6d587d',
    500: '#331a4a',
    950: '#000000',
  },
}
SCSS
$custom: #331a4a;
$custom-light: #6d587d;
$custom-dark: #000000;
JSON
{
  "hex": "#331a4a",
  "rgb": {
    "r": 51,
    "g": 26,
    "b": 74
  },
  "hsl": {
    "h": 271.25,
    "s": 48,
    "l": 19.608
  },
  "oklch": {
    "l": 0.27845,
    "c": 0.08742,
    "h": 305.5
  },
  "luminance": 0.01937
}

Semantic roles & 50–950 ramp

primary
#331A4A
secondary
#5F8040
accent
#D85091
background
#F6F5F7
surface
#ECE9EE
border
#C7C5C9
text
#070309
muted
#7A787B

Preview Lab

Preview with #331A4A

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

Preview Lab → · Contrast checker → · Palette generator →

#331A4A Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva