#331C56#331C56

#331C56 is a dark, moderate violet. Relative luminance 0.022; OKLCH L 29.1% C 0.101 H 298.1°. Best body text is #FFFFFF at 14.57:1 contrast (WCAG AA passes).

Color values

HEX#331C56
RGBrgb(51, 28, 86)
HSLhsl(264, 51%, 22%)
HSVhsv(264, 67%, 34%)
CMYKcmyk(40.7%, 67.4%, 0%, 66.3%)
CIE-LABlab(16.53, 25.47, -31.18)
CIE-LCHlch(16.53, 40.26, 309.25°)
OKLaboklab(29.14% 0.0475 -0.0887)
OKLCHoklch(29.14% 0.101 298.1)
XYZxyz(3.4598, 2.2062, 9.0458)
Luminance0.0221 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331C56 #3F561C
analogous
#1C2256 #331C56 #501C56
triadic
#331C56 #56331C #1C5633
tetradic
#331C56 #561C22 #3F561C #1C5650
square
#331C56 #561C22 #3F561C #1C5650
split-complementary
#331C56 #56501C #22561C
monochromatic
#0E0817 #180D28 #331C56 #4E2B84 #6A3AB2

Accessibility & contrast

On white

14.57
#331C56 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.44
#331C56 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331C56
14.57:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331C56#FFFFFF#000000##FFFFFF
##331C561.0014.571.4414.57
#FFFFFF14.571.0021.001.00
#0000001.4421.001.0021.00
##FFFFFF14.571.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002958
Deuteranopia (green-blind)
#032855
Tritanopia (blue-blind)
#2B2936
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #331c56;
/* rgb */ color: rgb(51, 28, 86);
/* oklch */ color: oklch(29.1% 0.101 298.1);
Tailwind
colors: {
  custom: {
    50: '#6e5986',
    500: '#331c56',
    950: '#000000',
  },
}
SCSS
$custom: #331c56;
$custom-light: #6e5986;
$custom-dark: #000000;
JSON
{
  "hex": "#331c56",
  "rgb": {
    "r": 51,
    "g": 28,
    "b": 86
  },
  "hsl": {
    "h": 263.793,
    "s": 50.877,
    "l": 22.353
  },
  "oklch": {
    "l": 0.29141,
    "c": 0.10059,
    "h": 298.1
  },
  "luminance": 0.02206
}

Semantic roles & 50–950 ramp

primary
#331C56
secondary
#6E8C42
accent
#DA4DA2
background
#F6F5F8
surface
#ECE9EF
border
#C7C5CA
text
#07030B
muted
#7A787C

Preview Lab

Preview with #331C56

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

Preview Lab → · Contrast checker → · Palette generator →

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