#402095#402095

#402095 is a dark, vivid violet. Relative luminance 0.043; OKLCH L 37.0% C 0.176 H 286.8°. Best body text is #FFFFFF at 11.30:1 contrast (WCAG AA passes).

Color values

HEX#402095
RGBrgb(64, 32, 149)
HSLhsl(256, 65%, 35%)
HSVhsv(256, 79%, 58%)
CMYKcmyk(57%, 78.5%, 0%, 41.6%)
CIE-LABlab(24.62, 44.55, -58.40)
CIE-LCHlch(24.62, 73.45, 307.33°)
OKLaboklab(37.02% 0.0506 -0.1681)
OKLCHoklch(37.02% 0.176 286.8)
XYZxyz(8.0541, 4.2925, 28.8321)
Luminance0.0429 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402095 #759520
analogous
#203B95 #402095 #7A2095
triadic
#402095 #954020 #209540
tetradic
#402095 #95203B #759520 #20957A
square
#402095 #95203B #759520 #20957A
split-complementary
#402095 #957A20 #3B9520
monochromatic
#150A30 #2A1563 #402095 #562BC7 #7955DA

Accessibility & contrast

On white

11.30
#402095 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.86
#402095 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402095
11.30:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402095#FFFFFF#000000##FFFFFF
##4020951.0011.301.8611.30
#FFFFFF11.301.0021.001.00
#0000001.8621.001.0021.00
##FFFFFF11.301.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003D98
Deuteranopia (green-blind)
#003793
Tritanopia (blue-blind)
#19425A
Achromatopsia (no color)
#3A3A3A

Design tokens & code

CSS
--color: #402095;
/* rgb */ color: rgb(64, 32, 149);
/* oklch */ color: oklch(37.0% 0.176 286.8);
Tailwind
colors: {
  custom: {
    50: '#7f60b5',
    500: '#402095',
    950: '#000000',
  },
}
SCSS
$custom: #402095;
$custom-light: #7f60b5;
$custom-dark: #000000;
JSON
{
  "hex": "#402095",
  "rgb": {
    "r": 64,
    "g": 32,
    "b": 149
  },
  "hsl": {
    "h": 256.41,
    "s": 64.641,
    "l": 35.49
  },
  "oklch": {
    "l": 0.37017,
    "c": 0.17558,
    "h": 286.8
  },
  "luminance": 0.04293
}

Semantic roles & 50–950 ramp

primary
#402095
secondary
#A1BE53
accent
#E840BA
background
#F8F5FB
surface
#EFEAF6
border
#CAC6D0
text
#0B0511
muted
#7C7980

Preview Lab

Preview with #402095

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

Preview Lab → · Contrast checker → · Palette generator →

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