#331B5C#331B5C

#331B5C is a dark, moderate violet. Relative luminance 0.023; OKLCH L 29.5% C 0.110 H 295.9°. Best body text is #FFFFFF at 14.46:1 contrast (WCAG AA passes).

Color values

HEX#331B5C
RGBrgb(51, 27, 92)
HSLhsl(262, 55%, 23%)
HSVhsv(262, 71%, 36%)
CMYKcmyk(44.6%, 70.7%, 0%, 63.9%)
CIE-LABlab(16.80, 27.91, -34.77)
CIE-LCHlch(16.80, 44.59, 308.75°)
OKLaboklab(29.49% 0.0481 -0.0993)
OKLCHoklch(29.49% 0.11 295.9)
XYZxyz(3.6884, 2.2603, 10.3651)
Luminance0.0226 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331B5C #445C1B
analogous
#1B235C #331B5C #531B5C
triadic
#331B5C #5C331B #1B5C33
tetradic
#331B5C #5C1B23 #445C1B #1B5C53
square
#331B5C #5C1B23 #445C1B #1B5C53
split-complementary
#331B5C #5C531B #235C1B
monochromatic
#0D0718 #190D2D #331B5C #4D298B #6737BB

Accessibility & contrast

On white

14.46
#331B5C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331B5C
14.46:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331B5C#FFFFFF#000000##FFFFFF
##331B5C1.0014.461.4514.46
#FFFFFF14.461.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.461.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A5E
Deuteranopia (green-blind)
#00295B
Tritanopia (blue-blind)
#282A39
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #331b5c;
/* rgb */ color: rgb(51, 27, 92);
/* oklch */ color: oklch(29.5% 0.110 295.9);
Tailwind
colors: {
  custom: {
    50: '#6f598b',
    500: '#331b5c',
    950: '#000000',
  },
}
SCSS
$custom: #331b5c;
$custom-light: #6f598b;
$custom-dark: #000000;
JSON
{
  "hex": "#331b5c",
  "rgb": {
    "r": 51,
    "g": 27,
    "b": 92
  },
  "hsl": {
    "h": 262.154,
    "s": 54.622,
    "l": 23.333
  },
  "oklch": {
    "l": 0.29487,
    "c": 0.1103,
    "h": 295.9
  },
  "luminance": 0.0226
}

Semantic roles & 50–950 ramp

primary
#331B5C
secondary
#749241
accent
#DE4AA7
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#08030C
muted
#7B787D

Preview Lab

Preview with #331B5C

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

Preview Lab → · Contrast checker → · Palette generator →

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