#331E6B#331E6B

#331E6B is a dark, vivid violet. Relative luminance 0.027; OKLCH L 31.3% C 0.126 H 289.6°. Best body text is #FFFFFF at 13.65:1 contrast (WCAG AA passes).

Color values

HEX#331E6B
RGBrgb(51, 30, 107)
HSLhsl(256, 56%, 27%)
HSVhsv(256, 72%, 42%)
CMYKcmyk(52.3%, 72%, 0%, 58%)
CIE-LABlab(18.77, 30.77, -41.45)
CIE-LCHlch(18.77, 51.62, 306.58°)
OKLaboklab(31.32% 0.0423 -0.1189)
OKLCHoklch(31.32% 0.126 289.6)
XYZxyz(4.4826, 2.6937, 14.1908)
Luminance0.0269 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331E6B #566B1E
analogous
#1E306B #331E6B #5A1E6B
triadic
#331E6B #6B331E #1E6B33
tetradic
#331E6B #6B1E30 #566B1E #1E6B5A
square
#331E6B #6B1E30 #566B1E #1E6B5A
split-complementary
#331E6B #6B5A1E #306B1E
monochromatic
#0B0718 #1C113B #331E6B #4A2B9B #623BC8

Accessibility & contrast

On white

13.65
#331E6B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.54
#331E6B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331E6B
13.65:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331E6B#FFFFFF#000000##FFFFFF
##331E6B1.0013.651.5413.65
#FFFFFF13.651.0021.001.00
#0000001.5421.001.0021.00
##FFFFFF13.651.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002F6D
Deuteranopia (green-blind)
#002C69
Tritanopia (blue-blind)
#203142
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #331e6b;
/* rgb */ color: rgb(51, 30, 107);
/* oklch */ color: oklch(31.3% 0.126 289.6);
Tailwind
colors: {
  custom: {
    50: '#715b96',
    500: '#331e6b',
    950: '#000000',
  },
}
SCSS
$custom: #331e6b;
$custom-light: #715b96;
$custom-dark: #000000;
JSON
{
  "hex": "#331e6b",
  "rgb": {
    "r": 51,
    "g": 30,
    "b": 107
  },
  "hsl": {
    "h": 256.364,
    "s": 56.204,
    "l": 26.863
  },
  "oklch": {
    "l": 0.31317,
    "c": 0.1262,
    "h": 289.6
  },
  "luminance": 0.02694
}

Semantic roles & 50–950 ramp

primary
#331E6B
secondary
#879F45
accent
#DF48B6
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040D
muted
#7B797E

Preview Lab

Preview with #331E6B

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

Preview Lab → · Contrast checker → · Palette generator →

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