#400642#400642

#400642 is a dark, moderate purple. Relative luminance 0.016; OKLCH L 26.8% C 0.114 H 326.6°. Best body text is #FFFFFF at 15.88:1 contrast (WCAG AA passes).

Color values

HEX#400642
RGBrgb(64, 6, 66)
HSLhsl(298, 83%, 14%)
HSVhsv(298, 91%, 26%)
CMYKcmyk(3%, 90.9%, 0%, 74.1%)
CIE-LABlab(13.31, 34.47, -22.47)
CIE-LCHlch(13.31, 41.15, 326.90°)
OKLaboklab(26.79% 0.095 -0.0625)
OKLCHoklch(26.79% 0.114 326.6)
XYZxyz(3.1628, 1.6138, 5.2981)
Luminance0.0161 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#400642 #084206
analogous
#220642 #400642 #420626
triadic
#400642 #424006 #064240
tetradic
#400642 #422206 #084206 #062642
square
#400642 #422206 #084206 #062642
split-complementary
#400642 #264206 #064222
monochromatic
#1B031C #1B031C #400642 #760B7A #AD10B2

Accessibility & contrast

On white

15.88
#400642 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.32
#400642 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #400642
15.88:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##400642#FFFFFF#000000##FFFFFF
##4006421.0015.881.3215.88
#FFFFFF15.881.0021.001.00
#0000001.3221.001.0021.00
##FFFFFF15.881.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001E44
Deuteranopia (green-blind)
#162541
Tritanopia (blue-blind)
#421124
Achromatopsia (no color)
#222222

Design tokens & code

CSS
--color: #400642;
/* rgb */ color: rgb(64, 6, 66);
/* oklch */ color: oklch(26.8% 0.114 326.6);
Tailwind
colors: {
  custom: {
    50: '#784f77',
    500: '#400642',
    950: '#000000',
  },
}
SCSS
$custom: #400642;
$custom-light: #784f77;
$custom-dark: #000000;
JSON
{
  "hex": "#400642",
  "rgb": {
    "r": 64,
    "g": 6,
    "b": 66
  },
  "hsl": {
    "h": 298,
    "s": 83.333,
    "l": 14.118
  },
  "oklch": {
    "l": 0.26789,
    "c": 0.11378,
    "h": 326.6
  },
  "luminance": 0.01614
}

Semantic roles & 50–950 ramp

primary
#400642
secondary
#258222
accent
#FA2E35
background
#F7F4F7
surface
#EDE7ED
border
#C8C3C8
text
#090208
muted
#7B787B

Preview Lab

Preview with #400642

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

Preview Lab → · Contrast checker → · Palette generator →

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