#402289#402289

#402289 is a dark, vivid violet. Relative luminance 0.040; OKLCH L 36.1% C 0.159 H 289.2°. Best body text is #FFFFFF at 11.62:1 contrast (WCAG AA passes).

Color values

HEX#402289
RGBrgb(64, 34, 137)
HSLhsl(257, 60%, 34%)
HSVhsv(257, 75%, 54%)
CMYKcmyk(53.3%, 75.2%, 0%, 46.3%)
CIE-LABlab(23.80, 40.00, -52.29)
CIE-LCHlch(23.80, 65.84, 307.41°)
OKLaboklab(36.09% 0.0523 -0.1503)
OKLCHoklch(36.09% 0.159 289.2)
XYZxyz(7.2004, 4.0399, 24.0624)
Luminance0.0404 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402289 #6B8922
analogous
#223789 #402289 #732289
triadic
#402289 #894022 #228940
tetradic
#402289 #892237 #6B8922 #228973
square
#402289 #892237 #6B8922 #228973
split-complementary
#402289 #897322 #378922
monochromatic
#120A27 #291658 #402289 #572EBA #7751D4

Accessibility & contrast

On white

11.62
#402289 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.81
#402289 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402289
11.62:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402289#FFFFFF#000000##FFFFFF
##4022891.0011.621.8111.62
#FFFFFF11.621.0021.001.00
#0000001.8121.001.0021.00
##FFFFFF11.621.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003B8C
Deuteranopia (green-blind)
#003687
Tritanopia (blue-blind)
#253E53
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #402289;
/* rgb */ color: rgb(64, 34, 137);
/* oklch */ color: oklch(36.1% 0.159 289.2);
Tailwind
colors: {
  custom: {
    50: '#7d60ac',
    500: '#402289',
    950: '#000000',
  },
}
SCSS
$custom: #402289;
$custom-light: #7d60ac;
$custom-dark: #000000;
JSON
{
  "hex": "#402289",
  "rgb": {
    "r": 64,
    "g": 34,
    "b": 137
  },
  "hsl": {
    "h": 257.476,
    "s": 60.234,
    "l": 33.529
  },
  "oklch": {
    "l": 0.36091,
    "c": 0.1591,
    "h": 289.2
  },
  "luminance": 0.0404
}

Semantic roles & 50–950 ramp

primary
#402289
secondary
#99B84F
accent
#E344B5
background
#F8F5FA
surface
#EFEAF4
border
#CAC6CE
text
#0A0510
muted
#7C797F

Preview Lab

Preview with #402289

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

Preview Lab → · Contrast checker → · Palette generator →

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