#4020A0#4020A0

#4020A0 is a dark, vivid violet. Relative luminance 0.047; OKLCH L 38.1% C 0.188 H 284.5°. Best body text is #FFFFFF at 10.87:1 contrast (WCAG AA passes).

Color values

HEX#4020A0
RGBrgb(64, 32, 160)
HSLhsl(255, 67%, 38%)
HSVhsv(255, 80%, 63%)
CMYKcmyk(60%, 80%, 0%, 37.3%)
CIE-LABlab(25.74, 47.74, -63.28)
CIE-LCHlch(25.74, 79.27, 307.03°)
OKLaboklab(38.14% 0.0473 -0.1824)
OKLCHoklch(38.14% 0.188 284.5)
XYZxyz(8.9741, 4.6605, 33.6776)
Luminance0.0466 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4020A0 #80A020
analogous
#2040A0 #4020A0 #8020A0
triadic
#4020A0 #A04020 #20A040
tetradic
#4020A0 #A02040 #80A020 #20A080
square
#4020A0 #A02040 #80A020 #20A080
split-complementary
#4020A0 #A08020 #40A020
monochromatic
#170C3A #2C166D #4020A0 #542AD3 #7D5CDE

Accessibility & contrast

On white

10.87
#4020A0 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.93
#4020A0 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4020A0
10.87:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4020A0#FFFFFF#000000##FFFFFF
##4020A01.0010.871.9310.87
#FFFFFF10.871.0021.001.00
#0000001.9321.001.0021.00
##FFFFFF10.871.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0041A4
Deuteranopia (green-blind)
#00399E
Tritanopia (blue-blind)
#014660
Achromatopsia (no color)
#3D3D3D

Design tokens & code

CSS
--color: #4020a0;
/* rgb */ color: rgb(64, 32, 160);
/* oklch */ color: oklch(38.1% 0.188 284.5);
Tailwind
colors: {
  custom: {
    50: '#8160bd',
    500: '#4020a0',
    950: '#000000',
  },
}
SCSS
$custom: #4020a0;
$custom-light: #8160bd;
$custom-dark: #000000;
JSON
{
  "hex": "#4020a0",
  "rgb": {
    "r": 64,
    "g": 32,
    "b": 160
  },
  "hsl": {
    "h": 255,
    "s": 66.667,
    "l": 37.647
  },
  "oklch": {
    "l": 0.38143,
    "c": 0.1884,
    "h": 284.5
  },
  "luminance": 0.04661
}

Semantic roles & 50–950 ramp

primary
#4020A0
secondary
#A8C359
accent
#EA3EBF
background
#F8F5FB
surface
#F0EAF7
border
#CBC6D0
text
#0C0512
muted
#7D7981

Preview Lab

Preview with #4020A0

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

Preview Lab → · Contrast checker → · Palette generator →

#4020A0 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva