#331F4F#331F4F

#331F4F is a dark, moderate violet. Relative luminance 0.022; OKLCH L 29.1% C 0.086 H 300.4°. Best body text is #FFFFFF at 14.49:1 contrast (WCAG AA passes).

Color values

HEX#331F4F
RGBrgb(51, 31, 79)
HSLhsl(265, 44%, 22%)
HSVhsv(265, 61%, 31%)
CMYKcmyk(35.4%, 60.8%, 0%, 69%)
CIE-LABlab(16.74, 21.44, -26.11)
CIE-LCHlch(16.74, 33.78, 309.39°)
OKLaboklab(29.12% 0.0433 -0.0738)
OKLCHoklch(29.12% 0.086 300.4)
XYZxyz(3.2662, 2.2483, 7.6575)
Luminance0.0225 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331F4F #3B4F1F
analogous
#1F234F #331F4F #4B1F4F
triadic
#331F4F #4F331F #1F4F33
tetradic
#331F4F #4F1F23 #3B4F1F #1F4F4B
square
#331F4F #4F1F23 #3B4F1F #1F4F4B
split-complementary
#331F4F #4F4B1F #234F1F
monochromatic
#0E0916 #170E23 #331F4F #4F307B #6C41A7

Accessibility & contrast

On white

14.49
#331F4F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331F4F
14.49:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331F4F#FFFFFF#000000##FFFFFF
##331F4F1.0014.491.4514.49
#FFFFFF14.491.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.491.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0B2951
Deuteranopia (green-blind)
#12294E
Tritanopia (blue-blind)
#2D2933
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #331f4f;
/* rgb */ color: rgb(51, 31, 79);
/* oklch */ color: oklch(29.1% 0.086 300.4);
Tailwind
colors: {
  custom: {
    50: '#6d5b81',
    500: '#331f4f',
    950: '#000000',
  },
}
SCSS
$custom: #331f4f;
$custom-light: #6d5b81;
$custom-dark: #000000;
JSON
{
  "hex": "#331f4f",
  "rgb": {
    "r": 51,
    "g": 31,
    "b": 79
  },
  "hsl": {
    "h": 265,
    "s": 43.636,
    "l": 21.569
  },
  "oklch": {
    "l": 0.29124,
    "c": 0.08556,
    "h": 300.4
  },
  "luminance": 0.02248
}

Semantic roles & 50–950 ramp

primary
#331F4F
secondary
#6A8446
accent
#D3549E
background
#F6F5F7
surface
#ECE9EE
border
#C7C5C9
text
#07040A
muted
#7A797C

Preview Lab

Preview with #331F4F

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

Preview Lab → · Contrast checker → · Palette generator →

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