#BA31C4#BA31C4

#BA31C4 is a mid, highly saturated purple. Relative luminance 0.166; OKLCH L 58.1% C 0.234 H 325.0°. Best body text is #FFFFFF at 4.86:1 contrast (WCAG AA passes).

Color values

HEX#BA31C4
RGBrgb(186, 49, 196)
HSLhsl(296, 60%, 48%)
HSVhsv(296, 75%, 77%)
CMYKcmyk(5.1%, 75%, 0%, 23.1%)
CIE-LABlab(47.78, 70.40, -48.12)
CIE-LCHlch(47.78, 85.27, 325.65°)
OKLaboklab(58.07% 0.1915 -0.134)
OKLCHoklch(58.07% 0.234 325)
XYZxyz(31.3111, 16.6233, 53.7733)
Luminance0.1662 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#BA31C4 #3BC431
analogous
#7031C4 #BA31C4 #C43185
triadic
#BA31C4 #C4BA31 #31C4BA
tetradic
#BA31C4 #C47031 #3BC431 #3185C4
square
#BA31C4 #C47031 #3BC431 #3185C4
split-complementary
#BA31C4 #85C431 #31C470
monochromatic
#5D1962 #8C2593 #BA31C4 #CE5CD6 #DD8DE2

Accessibility & contrast

On white

4.86
#BA31C4 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.32
#BA31C4 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #BA31C4
4.86:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##BA31C4#FFFFFF#000000##FFFFFF
##BA31C41.004.864.324.86
#FFFFFF4.861.0021.001.00
#0000004.3221.001.0021.00
##FFFFFF4.861.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0067C8
Deuteranopia (green-blind)
#5077C1
Tritanopia (blue-blind)
#BE4C79
Achromatopsia (no color)
#717171

Design tokens & code

CSS
--color: #ba31c4;
/* rgb */ color: rgb(186, 49, 196);
/* oklch */ color: oklch(58.1% 0.234 325.0);
Tailwind
colors: {
  custom: {
    50: '#d378d6',
    500: '#ba31c4',
    950: '#000000',
  },
}
SCSS
$custom: #ba31c4;
$custom-light: #d378d6;
$custom-dark: #000000;
JSON
{
  "hex": "#ba31c4",
  "rgb": {
    "r": 186,
    "g": 49,
    "b": 196
  },
  "hsl": {
    "h": 295.918,
    "s": 60,
    "l": 48.039
  },
  "oklch": {
    "l": 0.58068,
    "c": 0.23379,
    "h": 325
  },
  "luminance": 0.16621
}

Semantic roles & 50–950 ramp

primary
#BA31C4
secondary
#89CD84
accent
#E3454F
background
#FDF7FD
surface
#FAEEFA
border
#D3C9D3
text
#150A14
muted
#837C83

Preview Lab

Preview with #BA31C4

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

Preview Lab → · Contrast checker → · Palette generator →

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