#8040D1#8040D1

#8040D1 is a mid, highly saturated violet. Relative luminance 0.129; OKLCH L 52.9% C 0.211 H 299.2°. Best body text is #FFFFFF at 5.88:1 contrast (WCAG AA passes).

Color values

HEX#8040D1
RGBrgb(128, 64, 209)
HSLhsl(266, 61%, 54%)
HSVhsv(266, 69%, 82%)
CMYKcmyk(38.8%, 69.4%, 0%, 18%)
CIE-LABlab(42.55, 55.74, -64.48)
CIE-LCHlch(42.55, 85.23, 310.84°)
OKLaboklab(52.94% 0.1029 -0.184)
OKLCHoklch(52.94% 0.211 299.2)
XYZxyz(22.2412, 12.8592, 61.6195)
Luminance0.1286 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#8040D1 #91D140
analogous
#4048D1 #8040D1 #C840D1
triadic
#8040D1 #D18040 #40D180
tetradic
#8040D1 #D14048 #91D140 #40D1C8
square
#8040D1 #D14048 #91D140 #40D1C8
split-complementary
#8040D1 #D1C840 #48D140
monochromatic
#461D79 #6229AB #8040D1 #A171DD #C2A3E9

Accessibility & contrast

On white

5.88
#8040D1 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.57
#8040D1 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #8040D1
5.88:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##8040D1#FFFFFF#000000##FFFFFF
##8040D11.005.883.575.88
#FFFFFF5.881.0021.001.00
#0000003.5721.001.0021.00
##FFFFFF5.881.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0064D5
Deuteranopia (green-blind)
#0063CE
Tritanopia (blue-blind)
#6D6384
Achromatopsia (no color)
#646464

Design tokens & code

CSS
--color: #8040d1;
/* rgb */ color: rgb(128, 64, 209);
/* oklch */ color: oklch(52.9% 0.211 299.2);
Tailwind
colors: {
  custom: {
    50: '#ab7ae0',
    500: '#8040d1',
    950: '#000000',
  },
}
SCSS
$custom: #8040d1;
$custom-light: #ab7ae0;
$custom-dark: #000000;
JSON
{
  "hex": "#8040d1",
  "rgb": {
    "r": 128,
    "g": 64,
    "b": 209
  },
  "hsl": {
    "h": 266.483,
    "s": 61.181,
    "l": 53.529
  },
  "oklch": {
    "l": 0.5294,
    "c": 0.2108,
    "h": 299.2
  },
  "luminance": 0.12859
}

Semantic roles & 50–950 ramp

primary
#8040D1
secondary
#BAD597
accent
#E4449D
background
#FBF7FD
surface
#F6EEFB
border
#D0C9D4
text
#110915
muted
#807B83

Preview Lab

Preview with #8040D1

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

Preview Lab → · Contrast checker → · Palette generator →

#8040D1 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva