#402E66#402E66

#402E66 is a dark, moderate violet. Relative luminance 0.040; OKLCH L 35.1% C 0.095 H 296.0°. Best body text is #FFFFFF at 11.66:1 contrast (WCAG AA passes).

Color values

HEX#402E66
RGBrgb(64, 46, 102)
HSLhsl(259, 38%, 29%)
HSVhsv(259, 55%, 40%)
CMYKcmyk(37.3%, 54.9%, 0%, 60%)
CIE-LABlab(23.68, 22.22, -30.19)
CIE-LCHlch(23.68, 37.49, 306.35°)
OKLaboklab(35.13% 0.0416 -0.0854)
OKLCHoklch(35.13% 0.095 296)
XYZxyz(5.4890, 4.0032, 13.0513)
Luminance0.0400 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402E66 #54662E
analogous
#2E3866 #402E66 #5C2E66
triadic
#402E66 #66402E #2E6640
tetradic
#402E66 #662E38 #54662E #2E665C
square
#402E66 #662E38 #54662E #2E665C
split-complementary
#402E66 #665C2E #38662E
monochromatic
#0D0A15 #261B3C #402E66 #5A4190 #775AB5

Accessibility & contrast

On white

11.66
#402E66 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.80
#402E66 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402E66
11.66:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402E66#FFFFFF#000000##FFFFFF
##402E661.0011.661.8011.66
#FFFFFF11.661.0021.001.00
#0000001.8021.001.0021.00
##FFFFFF11.661.0021.001.00

Color blindness preview

Protanopia (red-blind)
#183968
Deuteranopia (green-blind)
#1D3865
Tritanopia (blue-blind)
#373945
Achromatopsia (no color)
#383838

Design tokens & code

CSS
--color: #402e66;
/* rgb */ color: rgb(64, 46, 102);
/* oklch */ color: oklch(35.1% 0.095 296.0);
Tailwind
colors: {
  custom: {
    50: '#776792',
    500: '#402e66',
    950: '#000000',
  },
}
SCSS
$custom: #402e66;
$custom-light: #776792;
$custom-dark: #000000;
JSON
{
  "hex": "#402e66",
  "rgb": {
    "r": 64,
    "g": 46,
    "b": 102
  },
  "hsl": {
    "h": 259.286,
    "s": 37.838,
    "l": 29.02
  },
  "oklch": {
    "l": 0.35125,
    "c": 0.09495,
    "h": 296
  },
  "luminance": 0.04003
}

Semantic roles & 50–950 ramp

primary
#402E66
secondary
#839858
accent
#CE5AA9
background
#F7F6F9
surface
#EDEBF1
border
#C8C6CB
text
#09060D
muted
#7B7A7E

Preview Lab

Preview with #402E66

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

Preview Lab → · Contrast checker → · Palette generator →

#402E66 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva