Skip to content

#ba2bf2

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

RGB
186, 43, 242
HSL
283°, 88%, 56%
CMYK
23, 82, 0, 5
Luminance
0.1858

Every format

HEX#ba2bf2
RGBrgb(186, 43, 242)
HSLhsl(283, 88%, 56%)
CMYKcmyk(23%, 82%, 0%, 5%)
LABlab(50.2 80.2 -70.5)
LCHlch(50.2 106.8 318.7)
OKLCHoklch(0.607 0.275 313.5)

Copy-ready code

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

Accessibility — WCAG contrast

Aa
#ba2bf2 on white: 4.45:1
AA ✗ fail · AA-large · AAA
Aa
#ba2bf2 on black: 4.72:1
AA ✓ pass · AA-large · AAA
true color
protanopia
deuteranopia
tritanopia

RGB percentages

Red72.9%
Green16.9%
Blue94.9%

CMYK percentages

Cyan23.1%
Magenta82.2%
Yellow0.0%
Key (black)5.1%

Color previews

#ba2bf2 text on a black background

contrast 4.72:1

Card sample

#ba2bf2 text on a white background

contrast 4.45:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(186, 43, 242, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(186, 43, 242, 0.45);
Border & gradient
Gradient panel
border: 3px solid #ba2bf2;
background: linear-gradient(135deg, #ba2bf2, #F22BA5);

Monochromatic scale

Palettes built from #ba2bf2

Shades — darker

Tints — lighter

Hue & tone neighbors

Color harmonies

Nearest named colors

Work with #ba2bf2 in the Color Lab