#331F50#331F50

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

Color values

HEX#331F50
RGBrgb(51, 31, 80)
HSLhsl(264, 44%, 22%)
HSVhsv(264, 61%, 31%)
CMYKcmyk(36.3%, 61.2%, 0%, 68.6%)
CIE-LABlab(16.81, 21.74, -26.67)
CIE-LCHlch(16.81, 34.41, 309.18°)
OKLaboklab(29.2% 0.0433 -0.0755)
OKLCHoklch(29.2% 0.087 299.9)
XYZxyz(3.3028, 2.2629, 7.8506)
Luminance0.0226 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331F50 #3C501F
analogous
#1F2450 #331F50 #4C1F50
triadic
#331F50 #50331F #1F5033
tetradic
#331F50 #501F24 #3C501F #1F504C
square
#331F50 #501F24 #3C501F #1F504C
split-complementary
#331F50 #504C1F #24501F
monochromatic
#0E0916 #170E24 #331F50 #4F307C #6B41A8

Accessibility & contrast

On white

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

On black

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

Best text color

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

Contrast matrix

fg \ bg##331F50#FFFFFF#000000##FFFFFF
##331F501.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)
#0A2952
Deuteranopia (green-blind)
#11294F
Tritanopia (blue-blind)
#2D2934
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #331f50;
/* rgb */ color: rgb(51, 31, 80);
/* oklch */ color: oklch(29.2% 0.087 299.9);
Tailwind
colors: {
  custom: {
    50: '#6d5b81',
    500: '#331f50',
    950: '#000000',
  },
}
SCSS
$custom: #331f50;
$custom-light: #6d5b81;
$custom-dark: #000000;
JSON
{
  "hex": "#331f50",
  "rgb": {
    "r": 51,
    "g": 31,
    "b": 80
  },
  "hsl": {
    "h": 264.49,
    "s": 44.144,
    "l": 21.765
  },
  "oklch": {
    "l": 0.29199,
    "c": 0.08702,
    "h": 299.9
  },
  "luminance": 0.02263
}

Semantic roles & 50–950 ramp

primary
#331F50
secondary
#6B8546
accent
#D454A0
background
#F6F5F7
surface
#ECE9EE
border
#C7C5C9
text
#07040A
muted
#7A797C

Preview Lab

Preview with #331F50

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

Preview Lab → · Contrast checker → · Palette generator →

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