#AF51DF#AF51DF

#AF51DF is a mid, highly saturated violet. Relative luminance 0.203; OKLCH L 61.4% C 0.215 H 312.2°. Best body text is #000000 at 5.07:1 contrast (WCAG AA passes).

Color values

HEX#AF51DF
RGBrgb(175, 81, 223)
HSLhsl(280, 69%, 60%)
HSVhsv(280, 64%, 87%)
CMYKcmyk(21.5%, 63.7%, 0%, 12.5%)
CIE-LABlab(52.21, 60.73, -56.59)
CIE-LCHlch(52.21, 83.01, 317.02°)
OKLaboklab(61.43% 0.1447 -0.1594)
OKLCHoklch(61.43% 0.215 312.2)
XYZxyz(33.9385, 20.3274, 71.9335)
Luminance0.2033 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF51DF #81DF51
analogous
#6851DF #AF51DF #DF51C8
triadic
#AF51DF #DFAF51 #51DFAF
tetradic
#AF51DF #DF6851 #81DF51 #51C8DF
square
#AF51DF #DF6851 #81DF51 #51C8DF
split-complementary
#AF51DF #C8DF51 #51DF68
monochromatic
#6F1C99 #9526CD #AF51DF #C785E9 #DFB8F2

Accessibility & contrast

On white

4.15
#AF51DF on #FFFFFF
AA ✗AA large ✓AAA ✗

On black

5.07
#AF51DF on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #AF51DF
5.07:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF51DF#FFFFFF#000000##000000
##AF51DF1.004.155.075.07
#FFFFFF4.151.0021.0021.00
#0000005.0721.001.001.00
##0000005.0721.001.001.00

Color blindness preview

Protanopia (red-blind)
#0278E3
Deuteranopia (green-blind)
#457EDC
Tritanopia (blue-blind)
#AA6D91
Achromatopsia (no color)
#7C7C7C

Design tokens & code

CSS
--color: #af51df;
/* rgb */ color: rgb(175, 81, 223);
/* oklch */ color: oklch(61.4% 0.215 312.2);
Tailwind
colors: {
  custom: {
    50: '#cb88ea',
    500: '#af51df',
    950: '#000000',
  },
}
SCSS
$custom: #af51df;
$custom-light: #cb88ea;
$custom-dark: #000000;
JSON
{
  "hex": "#af51df",
  "rgb": {
    "r": 175,
    "g": 81,
    "b": 223
  },
  "hsl": {
    "h": 279.718,
    "s": 68.932,
    "l": 59.608
  },
  "oklch": {
    "l": 0.61431,
    "c": 0.21526,
    "h": 312.2
  },
  "luminance": 0.20327
}

Semantic roles & 50–950 ramp

primary
#AF51DF
secondary
#BDE1AA
accent
#EC3C77
background
#FCF8FE
surface
#F9F0FD
border
#D2CBD5
text
#140C16
muted
#827D84

Preview Lab

Preview with #AF51DF

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

Preview Lab → · Contrast checker → · Palette generator →

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