#331B6B#331B6B

#331B6B is a dark, vivid violet. Relative luminance 0.025; OKLCH L 30.9% C 0.130 H 290.4°. Best body text is #FFFFFF at 13.91:1 contrast (WCAG AA passes).

Color values

HEX#331B6B
RGBrgb(51, 27, 107)
HSLhsl(258, 60%, 26%)
HSVhsv(258, 75%, 42%)
CMYKcmyk(52.3%, 74.8%, 0%, 58%)
CIE-LABlab(18.14, 32.52, -42.48)
CIE-LCHlch(18.14, 53.50, 307.43°)
OKLaboklab(30.87% 0.0454 -0.1219)
OKLCHoklch(30.87% 0.13 290.4)
XYZxyz(4.4103, 2.5490, 14.1667)
Luminance0.0255 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331B6B #536B1B
analogous
#1B2B6B #331B6B #5B1B6B
triadic
#331B6B #6B331B #1B6B33
tetradic
#331B6B #6B1B2B #536B1B #1B6B5B
square
#331B6B #6B1B2B #536B1B #1B6B5B
split-complementary
#331B6B #6B5B1B #2B6B1B
monochromatic
#0C0618 #1C0F3A #331B6B #4A279C #6235CC

Accessibility & contrast

On white

13.91
#331B6B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.51
#331B6B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331B6B
13.91:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331B6B#FFFFFF#000000##FFFFFF
##331B6B1.0013.911.5113.91
#FFFFFF13.911.0021.001.00
#0000001.5121.001.0021.00
##FFFFFF13.911.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E6D
Deuteranopia (green-blind)
#002A69
Tritanopia (blue-blind)
#203041
Achromatopsia (no color)
#2C2C2C

Design tokens & code

CSS
--color: #331b6b;
/* rgb */ color: rgb(51, 27, 107);
/* oklch */ color: oklch(30.9% 0.130 290.4);
Tailwind
colors: {
  custom: {
    50: '#715a96',
    500: '#331b6b',
    950: '#000000',
  },
}
SCSS
$custom: #331b6b;
$custom-light: #715a96;
$custom-dark: #000000;
JSON
{
  "hex": "#331b6b",
  "rgb": {
    "r": 51,
    "g": 27,
    "b": 107
  },
  "hsl": {
    "h": 258,
    "s": 59.701,
    "l": 26.275
  },
  "oklch": {
    "l": 0.30865,
    "c": 0.1301,
    "h": 290.4
  },
  "luminance": 0.02549
}

Semantic roles & 50–950 ramp

primary
#331B6B
secondary
#84A042
accent
#E345B3
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040D
muted
#7B797E

Preview Lab

Preview with #331B6B

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

Preview Lab → · Contrast checker → · Palette generator →

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