#331B49#331B49

#331B49 is a dark, moderate violet. Relative luminance 0.020; OKLCH L 27.9% C 0.084 H 305.7°. Best body text is #FFFFFF at 15.07:1 contrast (WCAG AA passes).

Color values

HEX#331B49
RGBrgb(51, 27, 73)
HSLhsl(271, 46%, 20%)
HSVhsv(271, 63%, 29%)
CMYKcmyk(30.1%, 63%, 0%, 71.4%)
CIE-LABlab(15.32, 22.29, -24.27)
CIE-LCHlch(15.32, 32.95, 312.57°)
OKLaboklab(27.94% 0.0492 -0.0684)
OKLCHoklch(27.94% 0.084 305.7)
XYZxyz(2.9595, 1.9687, 6.5261)
Luminance0.0197 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331B49 #31491B
analogous
#1C1B49 #331B49 #491B48
triadic
#331B49 #49331B #1B4933
tetradic
#331B49 #491C1B #31491B #1B4849
square
#331B49 #491C1B #31491B #1B4849
split-complementary
#331B49 #48491B #1B491C
monochromatic
#100816 #140A1C #331B49 #522C76 #713CA2

Accessibility & contrast

On white

15.07
#331B49 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.39
#331B49 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331B49
15.07:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331B49#FFFFFF#000000##FFFFFF
##331B491.0015.071.3915.07
#FFFFFF15.071.0021.001.00
#0000001.3921.001.0021.00
##FFFFFF15.071.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0A264B
Deuteranopia (green-blind)
#132648
Tritanopia (blue-blind)
#2F242F
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #331b49;
/* rgb */ color: rgb(51, 27, 73);
/* oklch */ color: oklch(27.9% 0.084 305.7);
Tailwind
colors: {
  custom: {
    50: '#6c587c',
    500: '#331b49',
    950: '#000000',
  },
}
SCSS
$custom: #331b49;
$custom-light: #6c587c;
$custom-dark: #000000;
JSON
{
  "hex": "#331b49",
  "rgb": {
    "r": 51,
    "g": 27,
    "b": 73
  },
  "hsl": {
    "h": 271.304,
    "s": 46,
    "l": 19.608
  },
  "oklch": {
    "l": 0.27945,
    "c": 0.08425,
    "h": 305.7
  },
  "luminance": 0.01969
}

Semantic roles & 50–950 ramp

primary
#331B49
secondary
#5F7F41
accent
#D65291
background
#F6F5F7
surface
#EBE9EE
border
#C6C5C9
text
#070309
muted
#7A787B

Preview Lab

Preview with #331B49

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

Preview Lab → · Contrast checker → · Palette generator →

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