#D040C2#D040C2

#D040C2 is a light, highly saturated purple. Relative luminance 0.210; OKLCH L 62.4% C 0.227 H 332.1°. Best body text is #000000 at 5.19:1 contrast (WCAG AA passes).

Color values

HEX#D040C2
RGBrgb(208, 64, 194)
HSLhsl(306, 61%, 53%)
HSVhsv(306, 69%, 82%)
CMYKcmyk(0%, 69.2%, 6.7%, 18.4%)
CIE-LABlab(52.92, 69.92, -38.59)
CIE-LCHlch(52.92, 79.86, 331.10°)
OKLaboklab(62.4% 0.2006 -0.106)
OKLCHoklch(62.4% 0.227 332.1)
XYZxyz(37.5835, 20.9747, 53.0975)
Luminance0.2097 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#D040C2 #40D04E
analogous
#9640D0 #D040C2 #D0407A
triadic
#D040C2 #C2D040 #40C2D0
tetradic
#D040C2 #D09640 #40D04E #407AD0
square
#D040C2 #D09640 #40D04E #407AD0
split-complementary
#D040C2 #7AD040 #40D096
monochromatic
#781E6F #A92A9D #D040C2 #DC71D2 #E8A2E1

Accessibility & contrast

On white

4.04
#D040C2 on #FFFFFF
AA ✗AA large ✓AAA ✗

On black

5.19
#D040C2 on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #D040C2
5.19:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##D040C2#FFFFFF#000000##000000
##D040C21.004.045.195.19
#FFFFFF4.041.0021.0021.00
#0000005.1921.001.001.00
##0000005.1921.001.001.00

Color blindness preview

Protanopia (red-blind)
#3871C6
Deuteranopia (green-blind)
#6D86BE
Tritanopia (blue-blind)
#D94F7C
Achromatopsia (no color)
#7E7E7E

Design tokens & code

CSS
--color: #d040c2;
/* rgb */ color: rgb(208, 64, 194);
/* oklch */ color: oklch(62.4% 0.227 332.1);
Tailwind
colors: {
  custom: {
    50: '#e281d5',
    500: '#d040c2',
    950: '#000000',
  },
}
SCSS
$custom: #d040c2;
$custom-light: #e281d5;
$custom-dark: #000000;
JSON
{
  "hex": "#d040c2",
  "rgb": {
    "r": 208,
    "g": 64,
    "b": 194
  },
  "hsl": {
    "h": 305.833,
    "s": 60.504,
    "l": 53.333
  },
  "oklch": {
    "l": 0.62397,
    "c": 0.22686,
    "h": 332.1
  },
  "luminance": 0.20972
}

Semantic roles & 50–950 ramp

primary
#D040C2
secondary
#97D59D
accent
#E45444
background
#FEF8FD
surface
#FDF0FA
border
#D5CBD3
text
#160B14
muted
#847C83

Preview Lab

Preview with #D040C2

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

Preview Lab → · Contrast checker → · Palette generator →

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