Skip to content

#ab2fab

a dark, vivid magenta / pink · warm · closest name: purple

RGB
171, 47, 171
HSL
300°, 57%, 43%
CMYK
0, 73, 0, 33
Luminance
0.1363

Every format

HEX#ab2fab
RGBrgb(171, 47, 171)
HSLhsl(300, 57%, 43%)
CMYKcmyk(0%, 73%, 0%, 33%)
LABlab(43.7 63.7 -40.1)
LCHlch(43.7 75.3 327.8)
OKLCHoklch(0.542 0.210 328.0)

Copy-ready code

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

Accessibility — WCAG contrast

Aa
#ab2fab on white: 5.64:1
AA ✓ pass · AA-large · AAA
Aa
#ab2fab on black: 3.73:1
AA ✗ fail · AA-large · AAA
true color
protanopia
deuteranopia
tritanopia

RGB percentages

Red67.1%
Green18.4%
Blue67.1%

CMYK percentages

Cyan0.0%
Magenta72.5%
Yellow0.0%
Key (black)32.9%

Color previews

#ab2fab text on a black background

contrast 3.73:1

Card sample

#ab2fab text on a white background

contrast 5.64:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(171, 47, 171, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(171, 47, 171, 0.45);
Border & gradient
Gradient panel
border: 3px solid #ab2fab;
background: linear-gradient(135deg, #ab2fab, #AB2F58);

Monochromatic scale

Palettes built from #ab2fab

Shades — darker

Tints — lighter

Hue & tone neighbors

Color harmonies

Nearest named colors

Work with #ab2fab in the Color Lab