#AF40E8#AF40E8

#AF40E8 is a mid, highly saturated violet. Relative luminance 0.186; OKLCH L 60.2% C 0.244 H 311.3°. Best body text is #000000 at 4.72:1 contrast (WCAG AA passes).

Color values

HEX#AF40E8
RGBrgb(175, 64, 232)
HSLhsl(280, 79%, 58%)
HSVhsv(280, 72%, 91%)
CMYKcmyk(24.6%, 72.4%, 0%, 9%)
CIE-LABlab(50.23, 69.74, -64.87)
CIE-LCHlch(50.23, 95.25, 317.07°)
OKLaboklab(60.2% 0.1615 -0.1835)
OKLCHoklch(60.2% 0.244 311.3)
XYZxyz(34.0753, 18.6078, 78.1249)
Luminance0.1861 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#AF40E8 #79E840
analogous
#5B40E8 #AF40E8 #E840CD
triadic
#AF40E8 #E8AF40 #40E8AF
tetradic
#AF40E8 #E85B40 #79E840 #40CDE8
square
#AF40E8 #E85B40 #79E840 #40CDE8
split-complementary
#AF40E8 #CDE840 #40E85B
monochromatic
#6D139B #9319D2 #AF40E8 #C677EF #DDADF5

Accessibility & contrast

On white

4.45
#AF40E8 on #FFFFFF
AA ✗AA large ✓AAA ✗

On black

4.72
#AF40E8 on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #AF40E8
4.72:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##AF40E8#FFFFFF#000000##000000
##AF40E81.004.454.724.72
#FFFFFF4.451.0021.0021.00
#0000004.7221.001.001.00
##0000004.7221.001.001.00

Color blindness preview

Protanopia (red-blind)
#0072ED
Deuteranopia (green-blind)
#2479E4
Tritanopia (blue-blind)
#A86691
Achromatopsia (no color)
#777777

Design tokens & code

CSS
--color: #af40e8;
/* rgb */ color: rgb(175, 64, 232);
/* oklch */ color: oklch(60.2% 0.244 311.3);
Tailwind
colors: {
  custom: {
    50: '#cc7ff0',
    500: '#af40e8',
    950: '#000000',
  },
}
SCSS
$custom: #af40e8;
$custom-light: #cc7ff0;
$custom-dark: #000000;
JSON
{
  "hex": "#af40e8",
  "rgb": {
    "r": 175,
    "g": 64,
    "b": 232
  },
  "hsl": {
    "h": 279.643,
    "s": 78.505,
    "l": 58.039
  },
  "oklch": {
    "l": 0.60197,
    "c": 0.24445,
    "h": 311.3
  },
  "luminance": 0.18607
}

Semantic roles & 50–950 ramp

primary
#AF40E8
secondary
#B7E3A0
accent
#F53375
background
#FDF8FE
surface
#FAEFFD
border
#D3CAD5
text
#140B17
muted
#837C85

Preview Lab

Preview with #AF40E8

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

Preview Lab → · Contrast checker → · Palette generator →

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