#B040C9#B040C9

#B040C9 is a mid, highly saturated purple. Relative luminance 0.171; OKLCH L 58.3% C 0.217 H 319.7°. Best body text is #FFFFFF at 4.75:1 contrast (WCAG AA passes).

Color values

HEX#B040C9
RGBrgb(176, 64, 201)
HSLhsl(289, 56%, 52%)
HSVhsv(289, 68%, 79%)
CMYKcmyk(12.4%, 68.2%, 0%, 21.2%)
CIE-LABlab(48.41, 63.88, -50.10)
CIE-LCHlch(48.41, 81.18, 321.89°)
OKLaboklab(58.3% 0.1656 -0.1402)
OKLCHoklch(58.3% 0.217 319.7)
XYZxyz(30.2792, 17.1154, 56.9557)
Luminance0.1711 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#B040C9 #59C940
analogous
#6C40C9 #B040C9 #C9409E
triadic
#B040C9 #C9B040 #40C9B0
tetradic
#B040C9 #C96C40 #59C940 #409EC9
square
#B040C9 #C96C40 #59C940 #409EC9
split-complementary
#B040C9 #9EC940 #40C96C
monochromatic
#611F6F #8A2D9F #B040C9 #C470D6 #D79FE4

Accessibility & contrast

On white

4.75
#B040C9 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.42
#B040C9 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #B040C9
4.75:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##B040C9#FFFFFF#000000##FFFFFF
##B040C91.004.754.424.75
#FFFFFF4.751.0021.001.00
#0000004.4221.001.0021.00
##FFFFFF4.751.0021.001.00

Color blindness preview

Protanopia (red-blind)
#016BCD
Deuteranopia (green-blind)
#4B77C6
Tritanopia (blue-blind)
#B05980
Achromatopsia (no color)
#737373

Design tokens & code

CSS
--color: #b040c9;
/* rgb */ color: rgb(176, 64, 201);
/* oklch */ color: oklch(58.3% 0.217 319.7);
Tailwind
colors: {
  custom: {
    50: '#cb7eda',
    500: '#b040c9',
    950: '#000000',
  },
}
SCSS
$custom: #b040c9;
$custom-light: #cb7eda;
$custom-dark: #000000;
JSON
{
  "hex": "#b040c9",
  "rgb": {
    "r": 176,
    "g": 64,
    "b": 201
  },
  "hsl": {
    "h": 289.051,
    "s": 55.918,
    "l": 51.961
  },
  "oklch": {
    "l": 0.58304,
    "c": 0.21701,
    "h": 319.7
  },
  "luminance": 0.17114
}

Semantic roles & 50–950 ramp

primary
#B040C9
secondary
#9FD094
accent
#DF4964
background
#FCF8FD
surface
#F9EFFB
border
#D2CAD4
text
#140B15
muted
#827C83

Preview Lab

Preview with #B040C9

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

Preview Lab → · Contrast checker → · Palette generator →

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