#331A5F#331A5F

#331A5F is a dark, moderate violet. Relative luminance 0.023; OKLCH L 29.6% C 0.116 H 295.0°. Best body text is #FFFFFF at 14.44:1 contrast (WCAG AA passes).

Color values

HEX#331A5F
RGBrgb(51, 26, 95)
HSLhsl(262, 57%, 24%)
HSVhsv(262, 73%, 37%)
CMYKcmyk(46.3%, 72.6%, 0%, 62.7%)
CIE-LABlab(16.84, 29.42, -36.70)
CIE-LCHlch(16.84, 47.04, 308.71°)
OKLaboklab(29.6% 0.0488 -0.1049)
OKLCHoklch(29.6% 0.116 295)
XYZxyz(3.7996, 2.2687, 11.0620)
Luminance0.0227 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331A5F #465F1A
analogous
#1A235F #331A5F #551A5F
triadic
#331A5F #5F331A #1A5F33
tetradic
#331A5F #5F1A23 #465F1A #1A5F55
square
#331A5F #5F1A23 #465F1A #1A5F55
split-complementary
#331A5F #5F551A #235F1A
monochromatic
#0D0718 #190D2F #331A5F #4D278F #6734BF

Accessibility & contrast

On white

14.44
#331A5F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331A5F
14.44:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331A5F#FFFFFF#000000##FFFFFF
##331A5F1.0014.441.4514.44
#FFFFFF14.441.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.441.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A61
Deuteranopia (green-blind)
#00285E
Tritanopia (blue-blind)
#272B3A
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #331a5f;
/* rgb */ color: rgb(51, 26, 95);
/* oklch */ color: oklch(29.6% 0.116 295.0);
Tailwind
colors: {
  custom: {
    50: '#6f588d',
    500: '#331a5f',
    950: '#000000',
  },
}
SCSS
$custom: #331a5f;
$custom-light: #6f588d;
$custom-dark: #000000;
JSON
{
  "hex": "#331a5f",
  "rgb": {
    "r": 51,
    "g": 26,
    "b": 95
  },
  "hsl": {
    "h": 261.739,
    "s": 57.025,
    "l": 23.725
  },
  "oklch": {
    "l": 0.29598,
    "c": 0.11575,
    "h": 295
  },
  "luminance": 0.02269
}

Semantic roles & 50–950 ramp

primary
#331A5F
secondary
#769540
accent
#E048A9
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#08030C
muted
#7B787D

Preview Lab

Preview with #331A5F

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

Preview Lab → · Contrast checker → · Palette generator →

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