#AF40E1#AF40E1

#AF40E1 is a mid, highly saturated purple. Relative luminance 0.182; OKLCH L 59.7% C 0.238 H 313.0°. Best body text is #000000 at 4.64:1 contrast (WCAG AA passes).

Color values

HEX#AF40E1
RGBrgb(175, 64, 225)
HSLhsl(281, 73%, 57%)
HSVhsv(281, 72%, 88%)
CMYKcmyk(22.2%, 71.6%, 0%, 11.8%)
CIE-LABlab(49.76, 68.33, -61.66)
CIE-LCHlch(49.76, 92.04, 317.94°)
OKLaboklab(59.72% 0.1624 -0.1741)
OKLCHoklch(59.72% 0.238 313)
XYZxyz(33.1008, 18.2180, 72.9923)
Luminance0.1822 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF40E1 #72E140
analogous
#5E40E1 #AF40E1 #E140C3
triadic
#AF40E1 #E1AF40 #40E1AF
tetradic
#AF40E1 #E15E40 #72E140 #40C3E1
square
#AF40E1 #E15E40 #72E140 #40C3E1
split-complementary
#AF40E1 #C3E140 #40E15E
monochromatic
#6A1790 #911FC5 #AF40E1 #C575E9 #DBAAF2

Accessibility & contrast

On white

4.52
#AF40E1 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.64
#AF40E1 on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #AF40E1
4.64:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF40E1#FFFFFF#000000##000000
##AF40E11.004.524.644.64
#FFFFFF4.521.0021.0021.00
#0000004.6421.001.001.00
##0000004.6421.001.001.00

Color blindness preview

Protanopia (red-blind)
#0071E6
Deuteranopia (green-blind)
#3079DD
Tritanopia (blue-blind)
#AA638D
Achromatopsia (no color)
#767676

Design tokens & code

CSS
--color: #af40e1;
/* rgb */ color: rgb(175, 64, 225);
/* oklch */ color: oklch(59.7% 0.238 313.0);
Tailwind
colors: {
  custom: {
    50: '#cb7feb',
    500: '#af40e1',
    950: '#000000',
  },
}
SCSS
$custom: #af40e1;
$custom-light: #cb7feb;
$custom-dark: #000000;
JSON
{
  "hex": "#af40e1",
  "rgb": {
    "r": 175,
    "g": 64,
    "b": 225
  },
  "hsl": {
    "h": 281.366,
    "s": 72.851,
    "l": 56.667
  },
  "oklch": {
    "l": 0.59719,
    "c": 0.23811,
    "h": 313
  },
  "luminance": 0.18217
}

Semantic roles & 50–950 ramp

primary
#AF40E1
secondary
#B2DF9D
accent
#F03871
background
#FDF8FE
surface
#FAEFFD
border
#D3CAD5
text
#140B16
muted
#837C84

Preview Lab

Preview with #AF40E1

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

Preview Lab → · Contrast checker → · Palette generator →

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