#331D6A#331D6A

#331D6A is a dark, vivid violet. Relative luminance 0.026; OKLCH L 31.1% C 0.126 H 290.2°. Best body text is #FFFFFF at 13.77:1 contrast (WCAG AA passes).

Color values

HEX#331D6A
RGBrgb(51, 29, 106)
HSLhsl(257, 57%, 26%)
HSVhsv(257, 73%, 42%)
CMYKcmyk(51.9%, 72.6%, 0%, 58.4%)
CIE-LABlab(18.47, 31.04, -41.30)
CIE-LCHlch(18.47, 51.66, 306.93°)
OKLaboklab(31.07% 0.0436 -0.1184)
OKLCHoklch(31.07% 0.126 290.2)
XYZxyz(4.4054, 2.6230, 13.9070)
Luminance0.0262 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331D6A #546A1D
analogous
#1D2E6A #331D6A #5A1D6A
triadic
#331D6A #6A331D #1D6A33
tetradic
#331D6A #6A1D2E #546A1D #1D6A5A
square
#331D6A #6A1D2E #546A1D #1D6A5A
split-complementary
#331D6A #6A5A1D #2E6A1D
monochromatic
#0C0718 #1C103A #331D6A #4A2A9A #6239C9

Accessibility & contrast

On white

13.77
#331D6A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.52
#331D6A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331D6A
13.77:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331D6A#FFFFFF#000000##FFFFFF
##331D6A1.0013.771.5213.77
#FFFFFF13.771.0021.001.00
#0000001.5221.001.0021.00
##FFFFFF13.771.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E6C
Deuteranopia (green-blind)
#002B68
Tritanopia (blue-blind)
#213041
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #331d6a;
/* rgb */ color: rgb(51, 29, 106);
/* oklch */ color: oklch(31.1% 0.126 290.2);
Tailwind
colors: {
  custom: {
    50: '#715b95',
    500: '#331d6a',
    950: '#000000',
  },
}
SCSS
$custom: #331d6a;
$custom-light: #715b95;
$custom-dark: #000000;
JSON
{
  "hex": "#331d6a",
  "rgb": {
    "r": 51,
    "g": 29,
    "b": 106
  },
  "hsl": {
    "h": 257.143,
    "s": 57.037,
    "l": 26.471
  },
  "oklch": {
    "l": 0.31069,
    "c": 0.12619,
    "h": 290.2
  },
  "luminance": 0.02623
}

Semantic roles & 50–950 ramp

primary
#331D6A
secondary
#859F44
accent
#E048B5
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040D
muted
#7B797E

Preview Lab

Preview with #331D6A

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

Preview Lab → · Contrast checker → · Palette generator →

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