#402B90#402B90

#402B90 is a dark, vivid violet. Relative luminance 0.048; OKLCH L 38.0% C 0.157 H 285.7°. Best body text is #FFFFFF at 10.68:1 contrast (WCAG AA passes).

Color values

HEX#402B90
RGBrgb(64, 43, 144)
HSLhsl(252, 54%, 37%)
HSVhsv(252, 70%, 56%)
CMYKcmyk(55.6%, 70.1%, 0%, 43.5%)
CIE-LABlab(26.25, 37.12, -52.64)
CIE-LCHlch(26.25, 64.41, 305.19°)
OKLaboklab(38.03% 0.0427 -0.1513)
OKLCHoklch(38.03% 0.157 285.7)
XYZxyz(8.0108, 4.8309, 26.8905)
Luminance0.0483 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402B90 #7B902B
analogous
#2B4990 #402B90 #732B90
triadic
#402B90 #90402B #2B9040
tetradic
#402B90 #902B49 #7B902B #2B9073
square
#402B90 #902B49 #7B902B #2B9073
split-complementary
#402B90 #90732B #49902B
monochromatic
#160F32 #2B1D61 #402B90 #5539BF #7B65D1

Accessibility & contrast

On white

10.68
#402B90 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.97
#402B90 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402B90
10.68:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402B90#FFFFFF#000000##FFFFFF
##402B901.0010.681.9710.68
#FFFFFF10.681.0021.001.00
#0000001.9721.001.0021.00
##FFFFFF10.681.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004193
Deuteranopia (green-blind)
#003B8E
Tritanopia (blue-blind)
#1E455A
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #402b90;
/* rgb */ color: rgb(64, 43, 144);
/* oklch */ color: oklch(38.0% 0.157 285.7);
Tailwind
colors: {
  custom: {
    50: '#7d66b1',
    500: '#402b90',
    950: '#000000',
  },
}
SCSS
$custom: #402b90;
$custom-light: #7d66b1;
$custom-dark: #000000;
JSON
{
  "hex": "#402b90",
  "rgb": {
    "r": 64,
    "g": 43,
    "b": 144
  },
  "hsl": {
    "h": 252.475,
    "s": 54.011,
    "l": 36.667
  },
  "oklch": {
    "l": 0.38028,
    "c": 0.15721,
    "h": 285.7
  },
  "luminance": 0.04831
}

Semantic roles & 50–950 ramp

primary
#402B90
secondary
#A5B760
accent
#DD4ABF
background
#F8F6FB
surface
#EFEBF6
border
#CAC6D0
text
#0B0611
muted
#7C7A80

Preview Lab

Preview with #402B90

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

Preview Lab → · Contrast checker → · Palette generator →

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