#332162#332162

#332162 is a dark, moderate violet. Relative luminance 0.027; OKLCH L 31.0% C 0.110 H 291.4°. Best body text is #FFFFFF at 13.68:1 contrast (WCAG AA passes).

Color values

HEX#332162
RGBrgb(51, 33, 98)
HSLhsl(257, 50%, 26%)
HSVhsv(257, 66%, 38%)
CMYKcmyk(48%, 66.3%, 0%, 61.6%)
CIE-LABlab(18.68, 26.04, -35.69)
CIE-LCHlch(18.68, 44.18, 306.11°)
OKLaboklab(31.01% 0.0401 -0.102)
OKLCHoklch(31.01% 0.11 291.4)
XYZxyz(4.1131, 2.6732, 11.8522)
Luminance0.0267 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#332162 #506221
analogous
#213062 #332162 #532162
triadic
#332162 #623321 #216233
tetradic
#332162 #622130 #506221 #216253
square
#332162 #622130 #506221 #216253
split-complementary
#332162 #625321 #306221
monochromatic
#0C0817 #1B1234 #332162 #4B3090 #6340BE

Accessibility & contrast

On white

13.68
#332162 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.53
#332162 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #332162
13.68:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##332162#FFFFFF#000000##FFFFFF
##3321621.0013.681.5313.68
#FFFFFF13.681.0021.001.00
#0000001.5321.001.0021.00
##FFFFFF13.681.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E64
Deuteranopia (green-blind)
#002C61
Tritanopia (blue-blind)
#25303E
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #332162;
/* rgb */ color: rgb(51, 33, 98);
/* oklch */ color: oklch(31.0% 0.110 291.4);
Tailwind
colors: {
  custom: {
    50: '#6f5d8f',
    500: '#332162',
    950: '#000000',
  },
}
SCSS
$custom: #332162;
$custom-light: #6f5d8f;
$custom-dark: #000000;
JSON
{
  "hex": "#332162",
  "rgb": {
    "r": 51,
    "g": 33,
    "b": 98
  },
  "hsl": {
    "h": 256.615,
    "s": 49.618,
    "l": 25.686
  },
  "oklch": {
    "l": 0.3101,
    "c": 0.10955,
    "h": 291.4
  },
  "luminance": 0.02673
}

Semantic roles & 50–950 ramp

primary
#332162
secondary
#819649
accent
#D94FB3
background
#F6F5F8
surface
#ECE9F0
border
#C7C5CB
text
#08040C
muted
#7B797D

Preview Lab

Preview with #332162

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

Preview Lab → · Contrast checker → · Palette generator →

#332162 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva