#9840AF#9840AF

#9840AF is a mid, vivid purple. Relative luminance 0.134; OKLCH L 53.5% C 0.183 H 318.7°. Best body text is #FFFFFF at 5.70:1 contrast (WCAG AA passes).

Color values

HEX#9840AF
RGBrgb(152, 64, 175)
HSLhsl(288, 46%, 47%)
HSVhsv(288, 63%, 69%)
CMYKcmyk(13.1%, 63.4%, 0%, 31.4%)
CIE-LABlab(43.42, 53.29, -43.10)
CIE-LCHlch(43.42, 68.53, 321.03°)
OKLaboklab(53.51% 0.1373 -0.1205)
OKLCHoklch(53.51% 0.183 318.7)
XYZxyz(22.5191, 13.4383, 41.9568)
Luminance0.1344 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#9840AF #57AF40
analogous
#6140AF #9840AF #AF408F
triadic
#9840AF #AF9840 #40AF98
tetradic
#9840AF #AF6140 #57AF40 #408FAF
square
#9840AF #AF6140 #57AF40 #408FAF
split-complementary
#9840AF #8FAF40 #40AF61
monochromatic
#4A1F55 #713082 #9840AF #B365C7 #C992D7

Accessibility & contrast

On white

5.70
#9840AF on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.69
#9840AF on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #9840AF
5.70:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##9840AF#FFFFFF#000000##FFFFFF
##9840AF1.005.703.695.70
#FFFFFF5.701.0021.001.00
#0000003.6921.001.0021.00
##FFFFFF5.701.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1F61B2
Deuteranopia (green-blind)
#466AAC
Tritanopia (blue-blind)
#985372
Achromatopsia (no color)
#676767

Design tokens & code

CSS
--color: #9840af;
/* rgb */ color: rgb(152, 64, 175);
/* oklch */ color: oklch(53.5% 0.183 318.7);
Tailwind
colors: {
  custom: {
    50: '#b97bc7',
    500: '#9840af',
    950: '#000000',
  },
}
SCSS
$custom: #9840af;
$custom-light: #b97bc7;
$custom-dark: #000000;
JSON
{
  "hex": "#9840af",
  "rgb": {
    "r": 152,
    "g": 64,
    "b": 175
  },
  "hsl": {
    "h": 287.568,
    "s": 46.444,
    "l": 46.863
  },
  "oklch": {
    "l": 0.53513,
    "c": 0.18266,
    "h": 318.7
  },
  "luminance": 0.13437
}

Semantic roles & 50–950 ramp

primary
#9840AF
secondary
#94C388
accent
#D6526D
background
#FBF7FC
surface
#F6EEF8
border
#D0C9D1
text
#120A13
muted
#817C82

Preview Lab

Preview with #9840AF

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

Preview Lab → · Contrast checker → · Palette generator →

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