#AF40CF#AF40CF

#AF40CF is a mid, highly saturated purple. Relative luminance 0.173; OKLCH L 58.5% C 0.222 H 317.7°. Best body text is #FFFFFF at 4.71:1 contrast (WCAG AA passes).

Color values

HEX#AF40CF
RGBrgb(175, 64, 207)
HSLhsl(287, 60%, 53%)
HSVhsv(287, 69%, 81%)
CMYKcmyk(15.5%, 69.1%, 0%, 18.8%)
CIE-LABlab(48.62, 64.80, -53.22)
CIE-LCHlch(48.62, 83.85, 320.60°)
OKLaboklab(58.54% 0.1641 -0.1494)
OKLCHoklch(58.54% 0.222 317.7)
XYZxyz(30.7735, 17.2871, 60.7351)
Luminance0.1729 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF40CF #60CF40
analogous
#6740CF #AF40CF #CF40A8
triadic
#AF40CF #CFAF40 #40CFAF
tetradic
#AF40CF #CF6740 #60CF40 #40A8CF
square
#AF40CF #CF6740 #60CF40 #40A8CF
split-complementary
#AF40CF #A8CF40 #40CF67
monochromatic
#631E77 #8C2AA8 #AF40CF #C371DB #D8A2E8

Accessibility & contrast

On white

4.71
#AF40CF on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.46
#AF40CF on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #AF40CF
4.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF40CF#FFFFFF#000000##FFFFFF
##AF40CF1.004.714.464.71
#FFFFFF4.711.0021.001.00
#0000004.4621.001.0021.00
##FFFFFF4.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006CD3
Deuteranopia (green-blind)
#4577CC
Tritanopia (blue-blind)
#AE5C83
Achromatopsia (no color)
#737373

Design tokens & code

CSS
--color: #af40cf;
/* rgb */ color: rgb(175, 64, 207);
/* oklch */ color: oklch(58.5% 0.222 317.7);
Tailwind
colors: {
  custom: {
    50: '#cb7ede',
    500: '#af40cf',
    950: '#000000',
  },
}
SCSS
$custom: #af40cf;
$custom-light: #cb7ede;
$custom-dark: #000000;
JSON
{
  "hex": "#af40cf",
  "rgb": {
    "r": 175,
    "g": 64,
    "b": 207
  },
  "hsl": {
    "h": 286.573,
    "s": 59.833,
    "l": 53.137
  },
  "oklch": {
    "l": 0.58544,
    "c": 0.22192,
    "h": 317.7
  },
  "luminance": 0.17286
}

Semantic roles & 50–950 ramp

primary
#AF40CF
secondary
#A4D497
accent
#E34568
background
#FCF8FD
surface
#F9EFFB
border
#D2CAD4
text
#140B15
muted
#827C83

Preview Lab

Preview with #AF40CF

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

Preview Lab → · Contrast checker → · Palette generator →

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