#331C4F#331C4F

#331C4F is a dark, moderate violet. Relative luminance 0.021; OKLCH L 28.6% C 0.091 H 301.7°. Best body text is #FFFFFF at 14.79:1 contrast (WCAG AA passes).

Color values

HEX#331C4F
RGBrgb(51, 28, 79)
HSLhsl(267, 48%, 21%)
HSVhsv(267, 65%, 31%)
CMYKcmyk(35.4%, 64.6%, 0%, 69%)
CIE-LABlab(16.00, 23.39, -27.30)
CIE-LCHlch(16.00, 35.94, 310.59°)
OKLaboklab(28.58% 0.0478 -0.0773)
OKLCHoklch(28.58% 0.091 301.7)
XYZxyz(3.1914, 2.0988, 7.6326)
Luminance0.0210 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331C4F #384F1C
analogous
#1C1E4F #331C4F #4C1C4F
triadic
#331C4F #4F331C #1C4F33
tetradic
#331C4F #4F1C1E #384F1C #1C4F4C
square
#331C4F #4F1C1E #384F1C #1C4F4C
split-complementary
#331C4F #4F4C1C #1E4F1C
monochromatic
#0F0817 #160C22 #331C4F #502C7C #6D3CA9

Accessibility & contrast

On white

14.79
#331C4F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.42
#331C4F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331C4F
14.79:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331C4F#FFFFFF#000000##FFFFFF
##331C4F1.0014.791.4214.79
#FFFFFF14.791.0021.001.00
#0000001.4221.001.0021.00
##FFFFFF14.791.0021.001.00

Color blindness preview

Protanopia (red-blind)
#042751
Deuteranopia (green-blind)
#0E284E
Tritanopia (blue-blind)
#2D2632
Achromatopsia (no color)
#282828

Design tokens & code

CSS
--color: #331c4f;
/* rgb */ color: rgb(51, 28, 79);
/* oklch */ color: oklch(28.6% 0.091 301.7);
Tailwind
colors: {
  custom: {
    50: '#6d5981',
    500: '#331c4f',
    950: '#000000',
  },
}
SCSS
$custom: #331c4f;
$custom-light: #6d5981;
$custom-dark: #000000;
JSON
{
  "hex": "#331c4f",
  "rgb": {
    "r": 51,
    "g": 28,
    "b": 79
  },
  "hsl": {
    "h": 267.059,
    "s": 47.664,
    "l": 20.98
  },
  "oklch": {
    "l": 0.28579,
    "c": 0.09085,
    "h": 301.7
  },
  "luminance": 0.02099
}

Semantic roles & 50–950 ramp

primary
#331C4F
secondary
#678542
accent
#D7519B
background
#F6F5F7
surface
#ECE9EE
border
#C7C5C9
text
#07030A
muted
#7A787C

Preview Lab

Preview with #331C4F

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

Preview Lab → · Contrast checker → · Palette generator →

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