#9840BF#9840BF

#9840BF is a mid, vivid purple. Relative luminance 0.141; OKLCH L 54.5% C 0.198 H 313.7°. Best body text is #FFFFFF at 5.50:1 contrast (WCAG AA passes).

Color values

HEX#9840BF
RGBrgb(152, 64, 191)
HSLhsl(282, 50%, 50%)
HSVhsv(282, 66%, 75%)
CMYKcmyk(20.4%, 66.5%, 0%, 25.1%)
CIE-LABlab(44.38, 56.57, -50.94)
CIE-LCHlch(44.38, 76.12, 318.00°)
OKLaboklab(54.52% 0.1369 -0.1434)
OKLCHoklch(54.52% 0.198 313.7)
XYZxyz(24.1847, 14.1045, 50.7286)
Luminance0.1410 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#9840BF #67BF40
analogous
#5940BF #9840BF #BF40A6
triadic
#9840BF #BF9840 #40BF98
tetradic
#9840BF #BF5940 #67BF40 #40A6BF
square
#9840BF #BF5940 #67BF40 #40A6BF
split-complementary
#9840BF #A6BF40 #40BF59
monochromatic
#4F2163 #743191 #9840BF #B16ECE #C99CDE

Accessibility & contrast

On white

5.50
#9840BF on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.82
#9840BF on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #9840BF
5.50:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##9840BF#FFFFFF#000000##FFFFFF
##9840BF1.005.503.825.50
#FFFFFF5.501.0021.001.00
#0000003.8221.001.0021.00
##FFFFFF5.501.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0064C3
Deuteranopia (green-blind)
#396BBC
Tritanopia (blue-blind)
#94597A
Achromatopsia (no color)
#696969

Design tokens & code

CSS
--color: #9840bf;
/* rgb */ color: rgb(152, 64, 191);
/* oklch */ color: oklch(54.5% 0.198 313.7);
Tailwind
colors: {
  custom: {
    50: '#ba7bd3',
    500: '#9840bf',
    950: '#000000',
  },
}
SCSS
$custom: #9840bf;
$custom-light: #ba7bd3;
$custom-dark: #000000;
JSON
{
  "hex": "#9840bf",
  "rgb": {
    "r": 152,
    "g": 64,
    "b": 191
  },
  "hsl": {
    "h": 281.575,
    "s": 49.804,
    "l": 50
  },
  "oklch": {
    "l": 0.5452,
    "c": 0.19823,
    "h": 313.7
  },
  "luminance": 0.14104
}

Semantic roles & 50–950 ramp

primary
#9840BF
secondary
#A2CA91
accent
#D94E79
background
#FBF7FD
surface
#F7EEFA
border
#D0C9D3
text
#120A14
muted
#817C83

Preview Lab

Preview with #9840BF

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

Preview Lab → · Contrast checker → · Palette generator →

#9840BF Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva