#AF40A2#AF40A2

#AF40A2 is a mid, vivid purple. Relative luminance 0.154; OKLCH L 56.0% C 0.184 H 332.6°. Best body text is #FFFFFF at 5.15:1 contrast (WCAG AA passes).

Color values

HEX#AF40A2
RGBrgb(175, 64, 162)
HSLhsl(307, 46%, 47%)
HSVhsv(307, 63%, 69%)
CMYKcmyk(0%, 63.4%, 7.4%, 31.4%)
CIE-LABlab(46.17, 56.76, -30.83)
CIE-LCHlch(46.17, 64.59, 331.50°)
OKLaboklab(55.98% 0.1631 -0.0843)
OKLCHoklch(55.98% 0.184 332.6)
XYZxyz(26.0342, 15.3914, 35.7750)
Luminance0.1539 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF40A2 #40AF4D
analogous
#8540AF #AF40A2 #AF406B
triadic
#AF40A2 #A2AF40 #40A2AF
tetradic
#AF40A2 #AF8540 #40AF4D #406BAF
square
#AF40A2 #AF8540 #40AF4D #406BAF
split-complementary
#AF40A2 #6BAF40 #40AF85
monochromatic
#551F4F #823079 #AF40A2 #C765BB #D792CF

Accessibility & contrast

On white

5.15
#AF40A2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.08
#AF40A2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #AF40A2
5.15:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF40A2#FFFFFF#000000##FFFFFF
##AF40A21.005.154.085.15
#FFFFFF5.151.0021.001.00
#0000004.0821.001.0021.00
##FFFFFF5.151.0021.001.00

Color blindness preview

Protanopia (red-blind)
#3C63A5
Deuteranopia (green-blind)
#61739F
Tritanopia (blue-blind)
#B6496B
Achromatopsia (no color)
#6D6D6D

Design tokens & code

CSS
--color: #af40a2;
/* rgb */ color: rgb(175, 64, 162);
/* oklch */ color: oklch(56.0% 0.184 332.6);
Tailwind
colors: {
  custom: {
    50: '#ca7cbe',
    500: '#af40a2',
    950: '#000000',
  },
}
SCSS
$custom: #af40a2;
$custom-light: #ca7cbe;
$custom-dark: #000000;
JSON
{
  "hex": "#af40a2",
  "rgb": {
    "r": 175,
    "g": 64,
    "b": 162
  },
  "hsl": {
    "h": 307.027,
    "s": 46.444,
    "l": 46.863
  },
  "oklch": {
    "l": 0.5598,
    "c": 0.18359,
    "h": 332.6
  },
  "luminance": 0.15389
}

Semantic roles & 50–950 ramp

primary
#AF40A2
secondary
#88C38F
accent
#D66152
background
#FCF7FB
surface
#F9EEF6
border
#D2C9D0
text
#140A12
muted
#827C81

Preview Lab

Preview with #AF40A2

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

Preview Lab → · Contrast checker → · Palette generator →

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