#331B61#331B61

#331B61 is a dark, moderate violet. Relative luminance 0.024; OKLCH L 29.9% C 0.117 H 293.9°. Best body text is #FFFFFF at 14.28:1 contrast (WCAG AA passes).

Color values

HEX#331B61
RGBrgb(51, 27, 97)
HSLhsl(261, 56%, 24%)
HSVhsv(261, 72%, 38%)
CMYKcmyk(47.4%, 72.2%, 0%, 62%)
CIE-LABlab(17.23, 29.44, -37.40)
CIE-LCHlch(17.23, 47.59, 308.21°)
OKLaboklab(29.93% 0.0474 -0.107)
OKLCHoklch(29.93% 0.117 293.9)
XYZxyz(3.9143, 2.3506, 11.5544)
Luminance0.0235 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331B61 #49611B
analogous
#1B2661 #331B61 #561B61
triadic
#331B61 #61331B #1B6133
tetradic
#331B61 #611B26 #49611B #1B6156
square
#331B61 #611B26 #49611B #1B6156
split-complementary
#331B61 #61561B #26611B
monochromatic
#0D0718 #1A0E31 #331B61 #4C2891 #6536C1

Accessibility & contrast

On white

14.28
#331B61 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.47
#331B61 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331B61
14.28:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331B61#FFFFFF#000000##FFFFFF
##331B611.0014.281.4714.28
#FFFFFF14.281.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.281.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002B63
Deuteranopia (green-blind)
#002960
Tritanopia (blue-blind)
#262C3B
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #331b61;
/* rgb */ color: rgb(51, 27, 97);
/* oklch */ color: oklch(29.9% 0.117 293.9);
Tailwind
colors: {
  custom: {
    50: '#6f598f',
    500: '#331b61',
    950: '#000000',
  },
}
SCSS
$custom: #331b61;
$custom-light: #6f598f;
$custom-dark: #000000;
JSON
{
  "hex": "#331b61",
  "rgb": {
    "r": 51,
    "g": 27,
    "b": 97
  },
  "hsl": {
    "h": 260.571,
    "s": 56.452,
    "l": 24.314
  },
  "oklch": {
    "l": 0.29933,
    "c": 0.11698,
    "h": 293.9
  },
  "luminance": 0.02351
}

Semantic roles & 50–950 ramp

primary
#331B61
secondary
#799741
accent
#E048AC
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#08030C
muted
#7B787D

Preview Lab

Preview with #331B61

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

Preview Lab → · Contrast checker → · Palette generator →

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