#BA40DB#BA40DB

#BA40DB is a mid, highly saturated purple. Relative luminance 0.192; OKLCH L 60.8% C 0.237 H 318.1°. Best body text is #000000 at 4.84:1 contrast (WCAG AA passes).

Color values

HEX#BA40DB
RGBrgb(186, 64, 219)
HSLhsl(287, 68%, 55%)
HSVhsv(287, 71%, 86%)
CMYKcmyk(15.1%, 70.8%, 0%, 14.1%)
CIE-LABlab(50.95, 69.37, -56.26)
CIE-LCHlch(50.95, 89.32, 320.96°)
OKLaboklab(60.76% 0.1763 -0.158)
OKLCHoklch(60.76% 0.237 318.1)
XYZxyz(34.8675, 19.2219, 68.8777)
Luminance0.1922 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#BA40DB #61DB40
analogous
#6C40DB #BA40DB #DB40AE
triadic
#BA40DB #DBBA40 #40DBBA
tetradic
#BA40DB #DB6C40 #61DB40 #40AEDB
square
#BA40DB #DB6C40 #61DB40 #40AEDB
split-complementary
#BA40DB #AEDB40 #40DB6C
monochromatic
#701987 #9A23BB #BA40DB #CD73E5 #DFA7EE

Accessibility & contrast

On white

4.34
#BA40DB on #FFFFFF
AA ✗AA large ✓AAA ✗

On black

4.84
#BA40DB on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #BA40DB
4.84:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##BA40DB#FFFFFF#000000##000000
##BA40DB1.004.344.844.84
#FFFFFF4.341.0021.0021.00
#0000004.8421.001.001.00
##0000004.8421.001.001.00

Color blindness preview

Protanopia (red-blind)
#0072DF
Deuteranopia (green-blind)
#477DD7
Tritanopia (blue-blind)
#B95F8A
Achromatopsia (no color)
#797979

Design tokens & code

CSS
--color: #ba40db;
/* rgb */ color: rgb(186, 64, 219);
/* oklch */ color: oklch(60.8% 0.237 318.1);
Tailwind
colors: {
  custom: {
    50: '#d37fe7',
    500: '#ba40db',
    950: '#000000',
  },
}
SCSS
$custom: #ba40db;
$custom-light: #d37fe7;
$custom-dark: #000000;
JSON
{
  "hex": "#ba40db",
  "rgb": {
    "r": 186,
    "g": 64,
    "b": 219
  },
  "hsl": {
    "h": 287.226,
    "s": 68.282,
    "l": 55.49
  },
  "oklch": {
    "l": 0.60762,
    "c": 0.23671,
    "h": 318.1
  },
  "luminance": 0.1922
}

Semantic roles & 50–950 ramp

primary
#BA40DB
secondary
#A9DC9B
accent
#EB3D62
background
#FDF8FE
surface
#FAEFFC
border
#D3CAD5
text
#150B16
muted
#837C84

Preview Lab

Preview with #BA40DB

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

Preview Lab → · Contrast checker → · Palette generator →

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