#331C74#331C74

#331C74 is a dark, vivid violet. Relative luminance 0.028; OKLCH L 31.9% C 0.140 H 287.5°. Best body text is #FFFFFF at 13.47:1 contrast (WCAG AA passes).

Color values

HEX#331C74
RGBrgb(51, 28, 116)
HSLhsl(256, 61%, 28%)
HSVhsv(256, 76%, 45%)
CMYKcmyk(56%, 75.9%, 0%, 54.5%)
CIE-LABlab(19.20, 34.75, -46.57)
CIE-LCHlch(19.20, 58.11, 306.73°)
OKLaboklab(31.89% 0.0424 -0.1339)
OKLCHoklch(31.89% 0.14 287.5)
XYZxyz(4.9319, 2.7950, 16.7992)
Luminance0.0279 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331C74 #5D741C
analogous
#1C3174 #331C74 #5F1C74
triadic
#331C74 #74331C #1C7433
tetradic
#331C74 #741C31 #5D741C #1C745F
square
#331C74 #741C31 #5D741C #1C745F
split-complementary
#331C74 #745F1C #31741C
monochromatic
#0B0619 #1D1043 #331C74 #4928A5 #623BD0

Accessibility & contrast

On white

13.47
#331C74 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331C74
13.47:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331C74#FFFFFF#000000##FFFFFF
##331C741.0013.471.5613.47
#FFFFFF13.471.0021.001.00
#0000001.5621.001.0021.00
##FFFFFF13.471.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003177
Deuteranopia (green-blind)
#002C72
Tritanopia (blue-blind)
#193446
Achromatopsia (no color)
#2F2F2F

Design tokens & code

CSS
--color: #331c74;
/* rgb */ color: rgb(51, 28, 116);
/* oklch */ color: oklch(31.9% 0.140 287.5);
Tailwind
colors: {
  custom: {
    50: '#735b9d',
    500: '#331c74',
    950: '#000000',
  },
}
SCSS
$custom: #331c74;
$custom-light: #735b9d;
$custom-dark: #000000;
JSON
{
  "hex": "#331c74",
  "rgb": {
    "r": 51,
    "g": 28,
    "b": 116
  },
  "hsl": {
    "h": 255.682,
    "s": 61.111,
    "l": 28.235
  },
  "oklch": {
    "l": 0.31885,
    "c": 0.14045,
    "h": 287.5
  },
  "luminance": 0.02795
}

Semantic roles & 50–950 ramp

primary
#331C74
secondary
#8EA843
accent
#E444BA
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#09040E
muted
#7B797E

Preview Lab

Preview with #331C74

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

Preview Lab → · Contrast checker → · Palette generator →

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