#B040A5#B040A5

#B040A5 is a mid, vivid purple. Relative luminance 0.156; OKLCH L 56.3% C 0.187 H 331.8°. Best body text is #FFFFFF at 5.09:1 contrast (WCAG AA passes).

Color values

HEX#B040A5
RGBrgb(176, 64, 165)
HSLhsl(306, 47%, 47%)
HSVhsv(306, 64%, 69%)
CMYKcmyk(0%, 63.6%, 6.2%, 31%)
CIE-LABlab(46.47, 57.51, -32.12)
CIE-LCHlch(46.47, 65.88, 330.81°)
OKLaboklab(56.28% 0.1645 -0.0881)
OKLCHoklch(56.28% 0.187 331.8)
XYZxyz(26.5294, 15.6155, 37.2068)
Luminance0.1561 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#B040A5 #40B04B
analogous
#8340B0 #B040A5 #B0406D
triadic
#B040A5 #A5B040 #40A5B0
tetradic
#B040A5 #B08340 #40B04B #406DB0
square
#B040A5 #B08340 #40B04B #406DB0
split-complementary
#B040A5 #6DB040 #40B083
monochromatic
#561F51 #83307B #B040A5 #C766BE #D893D1

Accessibility & contrast

On white

5.09
#B040A5 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.12
#B040A5 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #B040A5
5.09:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##B040A5#FFFFFF#000000##FFFFFF
##B040A51.005.094.125.09
#FFFFFF5.091.0021.001.00
#0000004.1221.001.0021.00
##FFFFFF5.091.0021.001.00

Color blindness preview

Protanopia (red-blind)
#3A64A8
Deuteranopia (green-blind)
#6074A2
Tritanopia (blue-blind)
#B74A6D
Achromatopsia (no color)
#6E6E6E

Design tokens & code

CSS
--color: #b040a5;
/* rgb */ color: rgb(176, 64, 165);
/* oklch */ color: oklch(56.3% 0.187 331.8);
Tailwind
colors: {
  custom: {
    50: '#cb7dc0',
    500: '#b040a5',
    950: '#000000',
  },
}
SCSS
$custom: #b040a5;
$custom-light: #cb7dc0;
$custom-dark: #000000;
JSON
{
  "hex": "#b040a5",
  "rgb": {
    "r": 176,
    "g": 64,
    "b": 165
  },
  "hsl": {
    "h": 305.893,
    "s": 46.667,
    "l": 47.059
  },
  "oklch": {
    "l": 0.56277,
    "c": 0.18659,
    "h": 331.8
  },
  "luminance": 0.15614
}

Semantic roles & 50–950 ramp

primary
#B040A5
secondary
#89C38F
accent
#D65F51
background
#FCF7FB
surface
#F9EEF7
border
#D2C9D0
text
#140A12
muted
#827C81

Preview Lab

Preview with #B040A5

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

Preview Lab → · Contrast checker → · Palette generator →

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