#331B6D#331B6D

#331B6D is a dark, vivid violet. Relative luminance 0.026; OKLCH L 31.1% C 0.133 H 289.8°. Best body text is #FFFFFF at 13.83:1 contrast (WCAG AA passes).

Color values

HEX#331B6D
RGBrgb(51, 27, 109)
HSLhsl(258, 60%, 27%)
HSVhsv(258, 75%, 43%)
CMYKcmyk(53.2%, 75.2%, 0%, 57.3%)
CIE-LABlab(18.33, 33.14, -43.48)
CIE-LCHlch(18.33, 54.67, 307.32°)
OKLaboklab(31.06% 0.0449 -0.1248)
OKLCHoklch(31.06% 0.133 289.8)
XYZxyz(4.5167, 2.5916, 14.7273)
Luminance0.0259 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331B6D #556D1B
analogous
#1B2C6D #331B6D #5C1B6D
triadic
#331B6D #6D331B #1B6D33
tetradic
#331B6D #6D1B2C #556D1B #1B6D5C
square
#331B6D #6D1B2C #556D1B #1B6D5C
split-complementary
#331B6D #6D5C1B #2C6D1B
monochromatic
#0B0619 #1C0F3C #331B6D #4A279E #6235CD

Accessibility & contrast

On white

13.83
#331B6D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.52
#331B6D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331B6D
13.83:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331B6D#FFFFFF#000000##FFFFFF
##331B6D1.0013.831.5213.83
#FFFFFF13.831.0021.001.00
#0000001.5221.001.0021.00
##FFFFFF13.831.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E6F
Deuteranopia (green-blind)
#002B6B
Tritanopia (blue-blind)
#1F3142
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #331b6d;
/* rgb */ color: rgb(51, 27, 109);
/* oklch */ color: oklch(31.1% 0.133 289.8);
Tailwind
colors: {
  custom: {
    50: '#715a98',
    500: '#331b6d',
    950: '#000000',
  },
}
SCSS
$custom: #331b6d;
$custom-light: #715a98;
$custom-dark: #000000;
JSON
{
  "hex": "#331b6d",
  "rgb": {
    "r": 51,
    "g": 27,
    "b": 109
  },
  "hsl": {
    "h": 257.561,
    "s": 60.294,
    "l": 26.667
  },
  "oklch": {
    "l": 0.31057,
    "c": 0.13268,
    "h": 289.8
  },
  "luminance": 0.02592
}

Semantic roles & 50–950 ramp

primary
#331B6D
secondary
#86A242
accent
#E344B5
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040E
muted
#7B797E

Preview Lab

Preview with #331B6D

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

Preview Lab → · Contrast checker → · Palette generator →

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