#AB40C7#AB40C7

#AB40C7 is a mid, highly saturated purple. Relative luminance 0.164; OKLCH L 57.5% C 0.213 H 318.6°. Best body text is #FFFFFF at 4.90:1 contrast (WCAG AA passes).

Color values

HEX#AB40C7
RGBrgb(171, 64, 199)
HSLhsl(288, 55%, 52%)
HSVhsv(288, 68%, 78%)
CMYKcmyk(14.1%, 67.8%, 0%, 22%)
CIE-LABlab(47.56, 62.40, -50.34)
CIE-LCHlch(47.56, 80.17, 321.10°)
OKLaboklab(57.51% 0.1598 -0.1411)
OKLCHoklch(57.51% 0.213 318.6)
XYZxyz(28.9354, 16.4495, 55.6727)
Luminance0.1645 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AB40C7 #5CC740
analogous
#6840C7 #AB40C7 #C7409F
triadic
#AB40C7 #C7AB40 #40C7AB
tetradic
#AB40C7 #C76840 #5CC740 #409FC7
square
#AB40C7 #C76840 #5CC740 #409FC7
split-complementary
#AB40C7 #9FC740 #40C768
monochromatic
#5D206D #852E9C #AB40C7 #C06FD5 #D59FE3

Accessibility & contrast

On white

4.90
#AB40C7 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.29
#AB40C7 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #AB40C7
4.90:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AB40C7#FFFFFF#000000##FFFFFF
##AB40C71.004.904.294.90
#FFFFFF4.901.0021.001.00
#0000004.2921.001.0021.00
##FFFFFF4.901.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006ACB
Deuteranopia (green-blind)
#4774C4
Tritanopia (blue-blind)
#AB597F
Achromatopsia (no color)
#717171

Design tokens & code

CSS
--color: #ab40c7;
/* rgb */ color: rgb(171, 64, 199);
/* oklch */ color: oklch(57.5% 0.213 318.6);
Tailwind
colors: {
  custom: {
    50: '#c87dd9',
    500: '#ab40c7',
    950: '#000000',
  },
}
SCSS
$custom: #ab40c7;
$custom-light: #c87dd9;
$custom-dark: #000000;
JSON
{
  "hex": "#ab40c7",
  "rgb": {
    "r": 171,
    "g": 64,
    "b": 199
  },
  "hsl": {
    "h": 287.556,
    "s": 54.656,
    "l": 51.569
  },
  "oklch": {
    "l": 0.57511,
    "c": 0.21315,
    "h": 318.6
  },
  "luminance": 0.16448
}

Semantic roles & 50–950 ramp

primary
#AB40C7
secondary
#A0CF94
accent
#DE4A69
background
#FCF8FD
surface
#F9EFFA
border
#D2CAD3
text
#140A15
muted
#827C83

Preview Lab

Preview with #AB40C7

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

Preview Lab → · Contrast checker → · Palette generator →

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