#402396#402396

#402396 is a dark, vivid violet. Relative luminance 0.045; OKLCH L 37.5% C 0.174 H 286.1°. Best body text is #FFFFFF at 11.06:1 contrast (WCAG AA passes).

Color values

HEX#402396
RGBrgb(64, 35, 150)
HSLhsl(255, 62%, 36%)
HSVhsv(255, 77%, 59%)
CMYKcmyk(57.3%, 76.7%, 0%, 41.2%)
CIE-LABlab(25.24, 43.34, -57.99)
CIE-LCHlch(25.24, 72.40, 306.77°)
OKLaboklab(37.49% 0.0481 -0.1669)
OKLCHoklch(37.49% 0.174 286.1)
XYZxyz(8.2187, 4.4936, 29.2825)
Luminance0.0449 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402396 #799623
analogous
#234096 #402396 #7A2396
triadic
#402396 #964023 #239640
tetradic
#402396 #962340 #799623 #23967A
square
#402396 #962340 #799623 #23967A
split-complementary
#402396 #967A23 #409623
monochromatic
#160C33 #2B1764 #402396 #552FC8 #7A5BD9

Accessibility & contrast

On white

11.06
#402396 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.90
#402396 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402396
11.06:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402396#FFFFFF#000000##FFFFFF
##4023961.0011.061.9011.06
#FFFFFF11.061.0021.001.00
#0000001.9021.001.0021.00
##FFFFFF11.061.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003F99
Deuteranopia (green-blind)
#003894
Tritanopia (blue-blind)
#17435B
Achromatopsia (no color)
#3C3C3C

Design tokens & code

CSS
--color: #402396;
/* rgb */ color: rgb(64, 35, 150);
/* oklch */ color: oklch(37.5% 0.174 286.1);
Tailwind
colors: {
  custom: {
    50: '#7f61b6',
    500: '#402396',
    950: '#000000',
  },
}
SCSS
$custom: #402396;
$custom-light: #7f61b6;
$custom-dark: #000000;
JSON
{
  "hex": "#402396",
  "rgb": {
    "r": 64,
    "g": 35,
    "b": 150
  },
  "hsl": {
    "h": 255.13,
    "s": 62.162,
    "l": 36.275
  },
  "oklch": {
    "l": 0.37485,
    "c": 0.17374,
    "h": 286.1
  },
  "luminance": 0.04494
}

Semantic roles & 50–950 ramp

primary
#402396
secondary
#A4BD58
accent
#E543BC
background
#F8F5FB
surface
#EFEAF6
border
#CAC6D0
text
#0B0511
muted
#7C7980

Preview Lab

Preview with #402396

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

Preview Lab → · Contrast checker → · Palette generator →

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