#331E51#331E51

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

Color values

HEX#331E51
RGBrgb(51, 30, 81)
HSLhsl(265, 46%, 22%)
HSVhsv(265, 63%, 32%)
CMYKcmyk(37%, 63%, 0%, 68.2%)
CIE-LABlab(16.63, 22.69, -27.64)
CIE-LCHlch(16.63, 35.76, 309.39°)
OKLaboklab(29.09% 0.0448 -0.0783)
OKLCHoklch(29.09% 0.09 299.8)
XYZxyz(3.3144, 2.2264, 8.0381)
Luminance0.0223 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331E51 #3C511E
analogous
#1E2351 #331E51 #4D1E51
triadic
#331E51 #51331E #1E5133
tetradic
#331E51 #511E23 #3C511E #1E514D
square
#331E51 #511E23 #3C511E #1E514D
split-complementary
#331E51 #514D1E #23511E
monochromatic
#0E0816 #170D24 #331E51 #4F2F7E #6B3FAA

Accessibility & contrast

On white

14.53
#331E51 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.45
#331E51 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331E51
14.53:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331E51#FFFFFF#000000##FFFFFF
##331E511.0014.531.4514.53
#FFFFFF14.531.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.531.0021.001.00

Color blindness preview

Protanopia (red-blind)
#062953
Deuteranopia (green-blind)
#0E2950
Tritanopia (blue-blind)
#2D2834
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #331e51;
/* rgb */ color: rgb(51, 30, 81);
/* oklch */ color: oklch(29.1% 0.090 299.8);
Tailwind
colors: {
  custom: {
    50: '#6d5b82',
    500: '#331e51',
    950: '#000000',
  },
}
SCSS
$custom: #331e51;
$custom-light: #6d5b82;
$custom-dark: #000000;
JSON
{
  "hex": "#331e51",
  "rgb": {
    "r": 51,
    "g": 30,
    "b": 81
  },
  "hsl": {
    "h": 264.706,
    "s": 45.946,
    "l": 21.765
  },
  "oklch": {
    "l": 0.29092,
    "c": 0.09021,
    "h": 299.8
  },
  "luminance": 0.02226
}

Semantic roles & 50–950 ramp

primary
#331E51
secondary
#6B8645
accent
#D6529F
background
#F6F5F8
surface
#ECE9EF
border
#C7C5CA
text
#07040A
muted
#7A797C

Preview Lab

Preview with #331E51

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

Preview Lab → · Contrast checker → · Palette generator →

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