Skip to content

#af2ad9

a balanced, vivid violet · warm · closest name: magenta

RGB
175, 42, 217
HSL
286°, 70%, 51%
CMYK
19, 81, 0, 15
Luminance
0.1578

Every format

HEX#af2ad9
RGBrgb(175, 42, 217)
HSLhsl(286, 70%, 51%)
CMYKcmyk(19%, 81%, 0%, 15%)
LABlab(46.7 74.1 -62.1)
LCHlch(46.7 96.7 320.0)
OKLCHoklch(0.574 0.253 316.1)

Copy-ready code

/* CSS */
color: #af2ad9;
background-color: #af2ad9;
/* Tailwind (arbitrary) */
class="text-[#af2ad9] bg-[#af2ad9]"
/* SCSS */
$brand: #af2ad9;
/* SwiftUI */
Color(red: 0.686, green: 0.165, blue: 0.851)
/* Android */
Color.parseColor("#af2ad9")

Accessibility — WCAG contrast

Aa
#af2ad9 on white: 5.05:1
AA ✓ pass · AA-large · AAA
Aa
#af2ad9 on black: 4.16:1
AA ✗ fail · AA-large · AAA
true color
protanopia
deuteranopia
tritanopia

RGB percentages

Red68.6%
Green16.5%
Blue85.1%

CMYK percentages

Cyan19.4%
Magenta80.6%
Yellow0.0%
Key (black)14.9%

Color previews

#af2ad9 text on a black background

contrast 4.16:1

Card sample

#af2ad9 text on a white background

contrast 5.05:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

color: #af2ad9;
Background color
Panel with #af2ad9 background
background-color: #af2ad9;
Text shadow — hex

Glowing headline

text-shadow: 2px 2px 8px #af2ad9;
Text shadow — RGB

Soft neon halo

text-shadow: 0 0 14px rgba(175, 42, 217, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(175, 42, 217, 0.45);
Border & gradient
Gradient panel
border: 3px solid #af2ad9;
background: linear-gradient(135deg, #af2ad9, #D92A8E);

Monochromatic scale

Palettes built from #af2ad9

Shades — darker

Tints — lighter

Hue & tone neighbors

Color harmonies

Nearest named colors

Work with #af2ad9 in the Color Lab