#AB42CB#AB42CB

#AB42CB is a mid, highly saturated purple. Relative luminance 0.169; OKLCH L 58.0% C 0.214 H 317.3°. Best body text is #FFFFFF at 4.80:1 contrast (WCAG AA passes).

Color values

HEX#AB42CB
RGBrgb(171, 66, 203)
HSLhsl(286, 57%, 53%)
HSVhsv(286, 67%, 80%)
CMYKcmyk(15.8%, 67.5%, 0%, 20.4%)
CIE-LABlab(48.09, 62.35, -51.80)
CIE-LCHlch(48.09, 81.06, 320.28°)
OKLaboklab(57.97% 0.1574 -0.1453)
OKLCHoklch(57.97% 0.214 317.3)
XYZxyz(29.5207, 16.8674, 58.1890)
Luminance0.1687 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AB42CB #62CB42
analogous
#6642CB #AB42CB #CB42A7
triadic
#AB42CB #CBAB42 #42CBAB
tetradic
#AB42CB #CB6642 #62CB42 #42A7CB
square
#AB42CB #CB6642 #62CB42 #42A7CB
split-complementary
#AB42CB #A7CB42 #42CB66
monochromatic
#602073 #872DA3 #AB42CB #C072D8 #D6A2E5

Accessibility & contrast

On white

4.80
#AB42CB on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.37
#AB42CB on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #AB42CB
4.80:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AB42CB#FFFFFF#000000##FFFFFF
##AB42CB1.004.804.374.80
#FFFFFF4.801.0021.001.00
#0000004.3721.001.0021.00
##FFFFFF4.801.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006CCF
Deuteranopia (green-blind)
#4575C8
Tritanopia (blue-blind)
#AA5C81
Achromatopsia (no color)
#727272

Design tokens & code

CSS
--color: #ab42cb;
/* rgb */ color: rgb(171, 66, 203);
/* oklch */ color: oklch(58.0% 0.214 317.3);
Tailwind
colors: {
  custom: {
    50: '#c87edb',
    500: '#ab42cb',
    950: '#000000',
  },
}
SCSS
$custom: #ab42cb;
$custom-light: #c87edb;
$custom-dark: #000000;
JSON
{
  "hex": "#ab42cb",
  "rgb": {
    "r": 171,
    "g": 66,
    "b": 203
  },
  "hsl": {
    "h": 285.985,
    "s": 56.846,
    "l": 52.745
  },
  "oklch": {
    "l": 0.57971,
    "c": 0.21428,
    "h": 317.3
  },
  "luminance": 0.16866
}

Semantic roles & 50–950 ramp

primary
#AB42CB
secondary
#A5D297
accent
#E0486B
background
#FCF8FD
surface
#F9EFFB
border
#D2CAD4
text
#140B15
muted
#827C83

Preview Lab

Preview with #AB42CB

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

Preview Lab → · Contrast checker → · Palette generator →

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