#331F6E#331F6E

#331F6E is a dark, vivid violet. Relative luminance 0.028; OKLCH L 31.8% C 0.129 H 288.4°. Best body text is #FFFFFF at 13.44:1 contrast (WCAG AA passes).

Color values

HEX#331F6E
RGBrgb(51, 31, 110)
HSLhsl(255, 56%, 28%)
HSVhsv(255, 72%, 43%)
CMYKcmyk(53.6%, 71.8%, 0%, 56.9%)
CIE-LABlab(19.26, 31.12, -42.60)
CIE-LCHlch(19.26, 52.75, 306.15°)
OKLaboklab(31.75% 0.0407 -0.1223)
OKLCHoklch(31.75% 0.129 288.4)
XYZxyz(4.6689, 2.8094, 15.0451)
Luminance0.0281 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331F6E #5A6E1F
analogous
#1F326E #331F6E #5A1F6E
triadic
#331F6E #6E331F #1F6E33
tetradic
#331F6E #6E1F32 #5A6E1F #1F6E5A
square
#331F6E #6E1F32 #5A6E1F #1F6E5A
split-complementary
#331F6E #6E5A1F #326E1F
monochromatic
#0B0718 #1D123E #331F6E #492C9E #623FC9

Accessibility & contrast

On white

13.44
#331F6E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.56
#331F6E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331F6E
13.44:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331F6E#FFFFFF#000000##FFFFFF
##331F6E1.0013.441.5613.44
#FFFFFF13.441.0021.001.00
#0000001.5621.001.0021.00
##FFFFFF13.441.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003070
Deuteranopia (green-blind)
#002D6C
Tritanopia (blue-blind)
#1E3344
Achromatopsia (no color)
#2F2F2F

Design tokens & code

CSS
--color: #331f6e;
/* rgb */ color: rgb(51, 31, 110);
/* oklch */ color: oklch(31.8% 0.129 288.4);
Tailwind
colors: {
  custom: {
    50: '#715c98',
    500: '#331f6e',
    950: '#000000',
  },
}
SCSS
$custom: #331f6e;
$custom-light: #715c98;
$custom-dark: #000000;
JSON
{
  "hex": "#331f6e",
  "rgb": {
    "r": 51,
    "g": 31,
    "b": 110
  },
  "hsl": {
    "h": 255.19,
    "s": 56.028,
    "l": 27.647
  },
  "oklch": {
    "l": 0.31753,
    "c": 0.12888,
    "h": 288.4
  },
  "luminance": 0.0281
}

Semantic roles & 50–950 ramp

primary
#331F6E
secondary
#8BA247
accent
#DF48B9
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040E
muted
#7B797E

Preview Lab

Preview with #331F6E

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

Preview Lab → · Contrast checker → · Palette generator →

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