#AB40CC#AB40CC

#AB40CC is a mid, highly saturated purple. Relative luminance 0.167; OKLCH L 57.8% C 0.218 H 317.1°. Best body text is #FFFFFF at 4.84:1 contrast (WCAG AA passes).

Color values

HEX#AB40CC
RGBrgb(171, 64, 204)
HSLhsl(286, 58%, 53%)
HSVhsv(286, 69%, 80%)
CMYKcmyk(16.2%, 68.6%, 0%, 20%)
CIE-LABlab(47.86, 63.36, -52.74)
CIE-LCHlch(47.86, 82.44, 320.23°)
OKLaboklab(57.83% 0.1595 -0.1481)
OKLCHoklch(57.83% 0.218 317.1)
XYZxyz(29.5255, 16.6856, 58.7804)
Luminance0.1668 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AB40CC #61CC40
analogous
#6540CC #AB40CC #CC40A7
triadic
#AB40CC #CCAB40 #40CCAB
tetradic
#AB40CC #CC6540 #61CC40 #40A7CC
square
#AB40CC #CC6540 #61CC40 #40A7CC
split-complementary
#AB40CC #A7CC40 #40CC65
monochromatic
#5F1F73 #872CA3 #AB40CC #C070D9 #D5A1E6

Accessibility & contrast

On white

4.84
#AB40CC on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.34
#AB40CC on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #AB40CC
4.84:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AB40CC#FFFFFF#000000##FFFFFF
##AB40CC1.004.844.344.84
#FFFFFF4.841.0021.001.00
#0000004.3421.001.0021.00
##FFFFFF4.841.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006BD0
Deuteranopia (green-blind)
#4375C9
Tritanopia (blue-blind)
#AA5B81
Achromatopsia (no color)
#727272

Design tokens & code

CSS
--color: #ab40cc;
/* rgb */ color: rgb(171, 64, 204);
/* oklch */ color: oklch(57.8% 0.218 317.1);
Tailwind
colors: {
  custom: {
    50: '#c87ddc',
    500: '#ab40cc',
    950: '#000000',
  },
}
SCSS
$custom: #ab40cc;
$custom-light: #c87ddc;
$custom-dark: #000000;
JSON
{
  "hex": "#ab40cc",
  "rgb": {
    "r": 171,
    "g": 64,
    "b": 204
  },
  "hsl": {
    "h": 285.857,
    "s": 57.851,
    "l": 52.549
  },
  "oklch": {
    "l": 0.57825,
    "c": 0.21766,
    "h": 317.1
  },
  "luminance": 0.16684
}

Semantic roles & 50–950 ramp

primary
#AB40CC
secondary
#A4D295
accent
#E1476B
background
#FCF8FD
surface
#F9EFFB
border
#D2CAD4
text
#140A15
muted
#827C83

Preview Lab

Preview with #AB40CC

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

Preview Lab → · Contrast checker → · Palette generator →

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