#331C5E#331C5E

#331C5E is a dark, moderate violet. Relative luminance 0.023; OKLCH L 29.8% C 0.112 H 294.7°. Best body text is #FFFFFF at 14.30:1 contrast (WCAG AA passes).

Color values

HEX#331C5E
RGBrgb(51, 28, 94)
HSLhsl(261, 54%, 24%)
HSVhsv(261, 70%, 37%)
CMYKcmyk(45.7%, 70.2%, 0%, 63.1%)
CIE-LABlab(17.19, 27.91, -35.47)
CIE-LCHlch(17.19, 45.13, 308.20°)
OKLaboklab(29.82% 0.0466 -0.1013)
OKLCHoklch(29.82% 0.112 294.7)
XYZxyz(3.8003, 2.3424, 10.8394)
Luminance0.0234 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331C5E #475E1C
analogous
#1C265E #331C5E #541C5E
triadic
#331C5E #5E331C #1C5E33
tetradic
#331C5E #5E1C26 #475E1C #1C5E54
square
#331C5E #5E1C26 #475E1C #1C5E54
split-complementary
#331C5E #5E541C #265E1C
monochromatic
#0D0718 #190E2F #331C5E #4D2A8D #6638BC

Accessibility & contrast

On white

14.30
#331C5E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.47
#331C5E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331C5E
14.30:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331C5E#FFFFFF#000000##FFFFFF
##331C5E1.0014.301.4714.30
#FFFFFF14.301.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.301.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002B60
Deuteranopia (green-blind)
#00295D
Tritanopia (blue-blind)
#272C3A
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #331c5e;
/* rgb */ color: rgb(51, 28, 94);
/* oklch */ color: oklch(29.8% 0.112 294.7);
Tailwind
colors: {
  custom: {
    50: '#6f5a8c',
    500: '#331c5e',
    950: '#000000',
  },
}
SCSS
$custom: #331c5e;
$custom-light: #6f5a8c;
$custom-dark: #000000;
JSON
{
  "hex": "#331c5e",
  "rgb": {
    "r": 51,
    "g": 28,
    "b": 94
  },
  "hsl": {
    "h": 260.909,
    "s": 54.098,
    "l": 23.922
  },
  "oklch": {
    "l": 0.29823,
    "c": 0.11152,
    "h": 294.7
  },
  "luminance": 0.02342
}

Semantic roles & 50–950 ramp

primary
#331C5E
secondary
#779342
accent
#DD4AAA
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#08040C
muted
#7B797D

Preview Lab

Preview with #331C5E

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

Preview Lab → · Contrast checker → · Palette generator →

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