#331A77#331A77

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

Color values

HEX#331A77
RGBrgb(51, 26, 119)
HSLhsl(256, 64%, 28%)
HSVhsv(256, 78%, 47%)
CMYKcmyk(57.1%, 78.2%, 0%, 53.3%)
CIE-LABlab(19.12, 36.77, -48.64)
CIE-LCHlch(19.12, 60.98, 307.09°)
OKLaboklab(31.91% 0.0433 -0.14)
OKLCHoklch(31.91% 0.147 287.2)
XYZxyz(5.0634, 2.7742, 17.7179)
Luminance0.0278 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331A77 #5E771A
analogous
#1A2F77 #331A77 #611A77
triadic
#331A77 #77331A #1A7733
tetradic
#331A77 #771A2F #5E771A #1A7761
square
#331A77 #771A2F #5E771A #1A7761
split-complementary
#331A77 #77611A #2F771A
monochromatic
#0B0519 #1D0F45 #331A77 #4925A9 #6238D3

Accessibility & contrast

On white

13.50
#331A77 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #331A77
13.50:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331A77#FFFFFF#000000##FFFFFF
##331A771.0013.501.5613.50
#FFFFFF13.501.0021.001.00
#0000001.5621.001.0021.00
##FFFFFF13.501.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00317A
Deuteranopia (green-blind)
#002C75
Tritanopia (blue-blind)
#163447
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #331a77;
/* rgb */ color: rgb(51, 26, 119);
/* oklch */ color: oklch(31.9% 0.147 287.2);
Tailwind
colors: {
  custom: {
    50: '#735a9f',
    500: '#331a77',
    950: '#000000',
  },
}
SCSS
$custom: #331a77;
$custom-light: #735a9f;
$custom-dark: #000000;
JSON
{
  "hex": "#331a77",
  "rgb": {
    "r": 51,
    "g": 26,
    "b": 119
  },
  "hsl": {
    "h": 256.129,
    "s": 64.138,
    "l": 28.431
  },
  "oklch": {
    "l": 0.31914,
    "c": 0.14651,
    "h": 287.2
  },
  "luminance": 0.02775
}

Semantic roles & 50–950 ramp

primary
#331A77
secondary
#8FAC41
accent
#E741BA
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#09040F
muted
#7B797E

Preview Lab

Preview with #331A77

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

Preview Lab → · Contrast checker → · Palette generator →

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