#331AA1#331AA1

#331AA1 is a dark, vivid violet. Relative luminance 0.040; OKLCH L 36.5% C 0.197 H 278.8°. Best body text is #FFFFFF at 11.65:1 contrast (WCAG AA passes).

Color values

HEX#331AA1
RGBrgb(51, 26, 161)
HSLhsl(251, 72%, 37%)
HSVhsv(251, 84%, 63%)
CMYKcmyk(68.3%, 83.9%, 0%, 36.9%)
CIE-LABlab(23.72, 49.41, -67.28)
CIE-LCHlch(23.72, 83.47, 306.30°)
OKLaboklab(36.48% 0.0301 -0.1943)
OKLCHoklch(36.48% 0.197 278.8)
XYZxyz(8.1656, 4.0151, 34.0560)
Luminance0.0402 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331AA1 #88A11A
analogous
#1A45A1 #331AA1 #771AA1
triadic
#331AA1 #A1331A #1AA133
tetradic
#331AA1 #A11A45 #88A11A #1AA177
square
#331AA1 #A11A45 #88A11A #1AA177
split-complementary
#331AA1 #A1771A #45A11A
monochromatic
#120938 #22116C #331AA1 #4423D6 #6D52E3

Accessibility & contrast

On white

11.65
#331AA1 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.80
#331AA1 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331AA1
11.65:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331AA1#FFFFFF#000000##FFFFFF
##331AA11.0011.651.8011.65
#FFFFFF11.651.0021.001.00
#0000001.8021.001.0021.00
##FFFFFF11.651.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003DA5
Deuteranopia (green-blind)
#00339F
Tritanopia (blue-blind)
#00455F
Achromatopsia (no color)
#383838

Design tokens & code

CSS
--color: #331aa1;
/* rgb */ color: rgb(51, 26, 161);
/* oklch */ color: oklch(36.5% 0.197 278.8);
Tailwind
colors: {
  custom: {
    50: '#7c5cbe',
    500: '#331aa1',
    950: '#000000',
  },
}
SCSS
$custom: #331aa1;
$custom-light: #7c5cbe;
$custom-dark: #000000;
JSON
{
  "hex": "#331aa1",
  "rgb": {
    "r": 51,
    "g": 26,
    "b": 161
  },
  "hsl": {
    "h": 251.111,
    "s": 72.193,
    "l": 36.667
  },
  "oklch": {
    "l": 0.36479,
    "c": 0.19659,
    "h": 278.8
  },
  "luminance": 0.04016
}

Semantic roles & 50–950 ramp

primary
#331AA1
secondary
#B0C651
accent
#EF39CD
background
#F8F5FB
surface
#EFE9F7
border
#CAC5D0
text
#0B0412
muted
#7C7981

Preview Lab

Preview with #331AA1

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

Preview Lab → · Contrast checker → · Palette generator →

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