#AF40DF#AF40DF

#AF40DF is a mid, highly saturated purple. Relative luminance 0.181; OKLCH L 59.6% C 0.236 H 313.5°. Best body text is #000000 at 4.62:1 contrast (WCAG AA passes).

Color values

HEX#AF40DF
RGBrgb(175, 64, 223)
HSLhsl(282, 71%, 56%)
HSVhsv(282, 71%, 87%)
CMYKcmyk(21.5%, 71.3%, 0%, 12.5%)
CIE-LABlab(49.63, 67.93, -60.74)
CIE-LCHlch(49.63, 91.13, 318.20°)
OKLaboklab(59.59% 0.1626 -0.1714)
OKLCHoklch(59.59% 0.236 313.5)
XYZxyz(32.8296, 18.1095, 71.5638)
Luminance0.1811 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF40DF #70DF40
analogous
#6040DF #AF40DF #DF40BF
triadic
#AF40DF #DFAF40 #40DFAF
tetradic
#AF40DF #DF6040 #70DF40 #40BFDF
square
#AF40DF #DF6040 #70DF40 #40BFDF
split-complementary
#AF40DF #BFDF40 #40DF60
monochromatic
#6A188D #9120C1 #AF40DF #C574E8 #DBA9F1

Accessibility & contrast

On white

4.54
#AF40DF on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.62
#AF40DF on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #AF40DF
4.62:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF40DF#FFFFFF#000000##000000
##AF40DF1.004.544.624.62
#FFFFFF4.541.0021.0021.00
#0000004.6221.001.001.00
##0000004.6221.001.001.00

Color blindness preview

Protanopia (red-blind)
#0070E4
Deuteranopia (green-blind)
#3379DC
Tritanopia (blue-blind)
#AA628C
Achromatopsia (no color)
#767676

Design tokens & code

CSS
--color: #af40df;
/* rgb */ color: rgb(175, 64, 223);
/* oklch */ color: oklch(59.6% 0.236 313.5);
Tailwind
colors: {
  custom: {
    50: '#cb7eea',
    500: '#af40df',
    950: '#000000',
  },
}
SCSS
$custom: #af40df;
$custom-light: #cb7eea;
$custom-dark: #000000;
JSON
{
  "hex": "#af40df",
  "rgb": {
    "r": 175,
    "g": 64,
    "b": 223
  },
  "hsl": {
    "h": 281.887,
    "s": 71.3,
    "l": 56.275
  },
  "oklch": {
    "l": 0.59585,
    "c": 0.2363,
    "h": 313.5
  },
  "luminance": 0.18108
}

Semantic roles & 50–950 ramp

primary
#AF40DF
secondary
#B0DE9D
accent
#EE3A70
background
#FDF8FE
surface
#FAEFFD
border
#D3CAD5
text
#140B16
muted
#837C84

Preview Lab

Preview with #AF40DF

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

Preview Lab → · Contrast checker → · Palette generator →

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