#BA42AB#BA42AB

#BA42AB is a mid, vivid purple. Relative luminance 0.173; OKLCH L 58.2% C 0.195 H 333.1°. Best body text is #FFFFFF at 4.71:1 contrast (WCAG AA passes).

Color values

HEX#BA42AB
RGBrgb(186, 66, 171)
HSLhsl(308, 48%, 49%)
HSVhsv(308, 65%, 73%)
CMYKcmyk(0%, 64.5%, 8.1%, 27.1%)
CIE-LABlab(48.61, 60.23, -32.20)
CIE-LCHlch(48.61, 68.30, 331.87°)
OKLaboklab(58.24% 0.1735 -0.0881)
OKLCHoklch(58.24% 0.195 333.1)
XYZxyz(29.5487, 17.2781, 40.2989)
Luminance0.1728 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#BA42AB #42BA51
analogous
#8D42BA #BA42AB #BA426F
triadic
#BA42AB #ABBA42 #42ABBA
tetradic
#BA42AB #BA8D42 #42BA51 #426FBA
square
#BA42AB #BA8D42 #42BA51 #426FBA
split-complementary
#BA42AB #6FBA42 #42BA8D
monochromatic
#602258 #8D3281 #BA42AB #CB6EC0 #DB9BD3

Accessibility & contrast

On white

4.71
#BA42AB on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.46
#BA42AB on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #BA42AB
4.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##BA42AB#FFFFFF#000000##FFFFFF
##BA42AB1.004.714.464.71
#FFFFFF4.711.0021.001.00
#0000004.4621.001.0021.00
##FFFFFF4.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#3E68AE
Deuteranopia (green-blind)
#677AA8
Tritanopia (blue-blind)
#C24C71
Achromatopsia (no color)
#737373

Design tokens & code

CSS
--color: #ba42ab;
/* rgb */ color: rgb(186, 66, 171);
/* oklch */ color: oklch(58.2% 0.195 333.1);
Tailwind
colors: {
  custom: {
    50: '#d27fc4',
    500: '#ba42ab',
    950: '#000000',
  },
}
SCSS
$custom: #ba42ab;
$custom-light: #d27fc4;
$custom-dark: #000000;
JSON
{
  "hex": "#ba42ab",
  "rgb": {
    "r": 186,
    "g": 66,
    "b": 171
  },
  "hsl": {
    "h": 307.5,
    "s": 47.619,
    "l": 49.412
  },
  "oklch": {
    "l": 0.58236,
    "c": 0.19459,
    "h": 333.1
  },
  "luminance": 0.17276
}

Semantic roles & 50–950 ramp

primary
#BA42AB
secondary
#90C897
accent
#D76151
background
#FDF8FC
surface
#FAEFF8
border
#D3CAD1
text
#140B12
muted
#837C81

Preview Lab

Preview with #BA42AB

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

Preview Lab → · Contrast checker → · Palette generator →

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