#331A5E#331A5E

#331A5E is a dark, moderate violet. Relative luminance 0.023; OKLCH L 29.5% C 0.114 H 295.4°. Best body text is #FFFFFF at 14.48:1 contrast (WCAG AA passes).

Color values

HEX#331A5E
RGBrgb(51, 26, 94)
HSLhsl(262, 57%, 24%)
HSVhsv(262, 72%, 37%)
CMYKcmyk(45.7%, 72.3%, 0%, 63.1%)
CIE-LABlab(16.75, 29.11, -36.18)
CIE-LCHlch(16.75, 46.44, 308.82°)
OKLaboklab(29.51% 0.049 -0.1034)
OKLCHoklch(29.51% 0.114 295.4)
XYZxyz(3.7545, 2.2507, 10.8241)
Luminance0.0225 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331A5E #455E1A
analogous
#1A235E #331A5E #551A5E
triadic
#331A5E #5E331A #1A5E33
tetradic
#331A5E #5E1A23 #455E1A #1A5E55
square
#331A5E #5E1A23 #455E1A #1A5E55
split-complementary
#331A5E #5E551A #235E1A
monochromatic
#0D0718 #190D2E #331A5E #4D278E #6735BE

Accessibility & contrast

On white

14.48
#331A5E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331A5E
14.48:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331A5E#FFFFFF#000000##FFFFFF
##331A5E1.0014.481.4514.48
#FFFFFF14.481.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.481.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A60
Deuteranopia (green-blind)
#00285D
Tritanopia (blue-blind)
#282A39
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #331a5e;
/* rgb */ color: rgb(51, 26, 94);
/* oklch */ color: oklch(29.5% 0.114 295.4);
Tailwind
colors: {
  custom: {
    50: '#6f588c',
    500: '#331a5e',
    950: '#000000',
  },
}
SCSS
$custom: #331a5e;
$custom-light: #6f588c;
$custom-dark: #000000;
JSON
{
  "hex": "#331a5e",
  "rgb": {
    "r": 51,
    "g": 26,
    "b": 94
  },
  "hsl": {
    "h": 262.059,
    "s": 56.667,
    "l": 23.529
  },
  "oklch": {
    "l": 0.29508,
    "c": 0.11443,
    "h": 295.4
  },
  "luminance": 0.02251
}

Semantic roles & 50–950 ramp

primary
#331A5E
secondary
#759440
accent
#E048A8
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#08030C
muted
#7B787D

Preview Lab

Preview with #331A5E

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

Preview Lab → · Contrast checker → · Palette generator →

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