#40219D#40219D

#40219D is a dark, vivid violet. Relative luminance 0.046; OKLCH L 37.9% C 0.184 H 285.0°. Best body text is #FFFFFF at 10.92:1 contrast (WCAG AA passes).

Color values

HEX#40219D
RGBrgb(64, 33, 157)
HSLhsl(255, 65%, 37%)
HSVhsv(255, 79%, 62%)
CMYKcmyk(59.2%, 79%, 0%, 38.4%)
CIE-LABlab(25.60, 46.40, -61.69)
CIE-LCHlch(25.60, 77.19, 306.95°)
OKLaboklab(37.95% 0.0475 -0.1778)
OKLCHoklch(37.95% 0.184 285)
XYZxyz(8.7422, 4.6115, 32.3212)
Luminance0.0461 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40219D #7E9D21
analogous
#21409D #40219D #7E219D
triadic
#40219D #9D4021 #219D40
tetradic
#40219D #9D2140 #7E9D21 #219D7E
square
#40219D #9D2140 #7E9D21 #219D7E
split-complementary
#40219D #9D7E21 #409D21
monochromatic
#170C38 #2B166A #40219D #552CD0 #7C5CDD

Accessibility & contrast

On white

10.92
#40219D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.92
#40219D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40219D
10.92:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40219D#FFFFFF#000000##FFFFFF
##40219D1.0010.921.9210.92
#FFFFFF10.921.0021.001.00
#0000001.9221.001.0021.00
##FFFFFF10.921.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0040A0
Deuteranopia (green-blind)
#00399B
Tritanopia (blue-blind)
#0A455F
Achromatopsia (no color)
#3D3D3D

Design tokens & code

CSS
--color: #40219d;
/* rgb */ color: rgb(64, 33, 157);
/* oklch */ color: oklch(37.9% 0.184 285.0);
Tailwind
colors: {
  custom: {
    50: '#8161bb',
    500: '#40219d',
    950: '#000000',
  },
}
SCSS
$custom: #40219d;
$custom-light: #8161bb;
$custom-dark: #000000;
JSON
{
  "hex": "#40219d",
  "rgb": {
    "r": 64,
    "g": 33,
    "b": 157
  },
  "hsl": {
    "h": 255,
    "s": 65.263,
    "l": 37.255
  },
  "oklch": {
    "l": 0.37948,
    "c": 0.184,
    "h": 285
  },
  "luminance": 0.04612
}

Semantic roles & 50–950 ramp

primary
#40219D
secondary
#A7C159
accent
#E840BE
background
#F8F5FB
surface
#F0EAF6
border
#CBC6D0
text
#0B0512
muted
#7C7981

Preview Lab

Preview with #40219D

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

Preview Lab → · Contrast checker → · Palette generator →

#40219D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva