#AF40CD#AF40CD

#AF40CD is a mid, highly saturated purple. Relative luminance 0.172; OKLCH L 58.4% C 0.220 H 318.2°. Best body text is #FFFFFF at 4.73:1 contrast (WCAG AA passes).

Color values

HEX#AF40CD
RGBrgb(175, 64, 205)
HSLhsl(287, 59%, 53%)
HSVhsv(287, 69%, 80%)
CMYKcmyk(14.6%, 68.8%, 0%, 19.6%)
CIE-LABlab(48.50, 64.42, -52.27)
CIE-LCHlch(48.50, 82.95, 320.94°)
OKLaboklab(58.42% 0.1642 -0.1466)
OKLCHoklch(58.42% 0.22 318.2)
XYZxyz(30.5305, 17.1899, 59.4556)
Luminance0.1719 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF40CD #5ECD40
analogous
#6840CD #AF40CD #CD40A4
triadic
#AF40CD #CDAF40 #40CDAF
tetradic
#AF40CD #CD6840 #5ECD40 #40A4CD
square
#AF40CD #CD6840 #5ECD40 #40A4CD
split-complementary
#AF40CD #A4CD40 #40CD68
monochromatic
#621E74 #8B2BA5 #AF40CD #C371DA #D8A1E6

Accessibility & contrast

On white

4.73
#AF40CD on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.44
#AF40CD on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #AF40CD
4.73:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF40CD#FFFFFF#000000##FFFFFF
##AF40CD1.004.734.444.73
#FFFFFF4.731.0021.001.00
#0000004.4421.001.0021.00
##FFFFFF4.731.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006CD1
Deuteranopia (green-blind)
#4777CA
Tritanopia (blue-blind)
#AE5B82
Achromatopsia (no color)
#737373

Design tokens & code

CSS
--color: #af40cd;
/* rgb */ color: rgb(175, 64, 205);
/* oklch */ color: oklch(58.4% 0.220 318.2);
Tailwind
colors: {
  custom: {
    50: '#cb7edd',
    500: '#af40cd',
    950: '#000000',
  },
}
SCSS
$custom: #af40cd;
$custom-light: #cb7edd;
$custom-dark: #000000;
JSON
{
  "hex": "#af40cd",
  "rgb": {
    "r": 175,
    "g": 64,
    "b": 205
  },
  "hsl": {
    "h": 287.234,
    "s": 58.506,
    "l": 52.745
  },
  "oklch": {
    "l": 0.58418,
    "c": 0.22014,
    "h": 318.2
  },
  "luminance": 0.17189
}

Semantic roles & 50–950 ramp

primary
#AF40CD
secondary
#A3D396
accent
#E24667
background
#FCF8FD
surface
#F9EFFB
border
#D2CAD4
text
#140B15
muted
#827C83

Preview Lab

Preview with #AF40CD

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

Preview Lab → · Contrast checker → · Palette generator →

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