#331D3F#331D3F

#331D3F is a dark, moderate violet. Relative luminance 0.019; OKLCH L 27.6% C 0.066 H 312.6°. Best body text is #FFFFFF at 15.13:1 contrast (WCAG AA passes).

Color values

HEX#331D3F
RGBrgb(51, 29, 63)
HSLhsl(279, 37%, 18%)
HSVhsv(279, 54%, 25%)
CMYKcmyk(19%, 54%, 0%, 75.3%)
CIE-LABlab(15.18, 18.21, -17.55)
CIE-LCHlch(15.18, 25.29, 316.06°)
OKLaboklab(27.63% 0.0449 -0.0488)
OKLCHoklch(27.63% 0.066 312.6)
XYZxyz(2.7017, 1.9415, 4.9341)
Luminance0.0194 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331D3F #293F1D
analogous
#221D3F #331D3F #3F1D3A
triadic
#331D3F #3F331D #1D3F33
tetradic
#331D3F #3F221D #293F1D #1D3A3F
square
#331D3F #3F221D #293F1D #1D3A3F
split-complementary
#331D3F #3A3F1D #1D3F22
monochromatic
#110A15 #110A15 #331D3F #553069 #774493

Accessibility & contrast

On white

15.13
#331D3F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331D3F
15.13:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331D3F#FFFFFF#000000##FFFFFF
##331D3F1.0015.131.3915.13
#FFFFFF15.131.0021.001.00
#0000001.3921.001.0021.00
##FFFFFF15.131.0021.001.00

Color blindness preview

Protanopia (red-blind)
#162540
Deuteranopia (green-blind)
#1C273E
Tritanopia (blue-blind)
#32222B
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #331d3f;
/* rgb */ color: rgb(51, 29, 63);
/* oklch */ color: oklch(27.6% 0.066 312.6);
Tailwind
colors: {
  custom: {
    50: '#6b5974',
    500: '#331d3f',
    950: '#000000',
  },
}
SCSS
$custom: #331d3f;
$custom-light: #6b5974;
$custom-dark: #000000;
JSON
{
  "hex": "#331d3f",
  "rgb": {
    "r": 51,
    "g": 29,
    "b": 63
  },
  "hsl": {
    "h": 278.824,
    "s": 36.957,
    "l": 18.039
  },
  "oklch": {
    "l": 0.27627,
    "c": 0.06633,
    "h": 312.6
  },
  "luminance": 0.01941
}

Semantic roles & 50–950 ramp

primary
#331D3F
secondary
#557444
accent
#CD5B83
background
#F6F5F7
surface
#EBE9ED
border
#C6C5C8
text
#070308
muted
#7A787B

Preview Lab

Preview with #331D3F

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

Preview Lab → · Contrast checker → · Palette generator →

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