#9A40DB#9A40DB

#9A40DB is a mid, highly saturated violet. Relative luminance 0.157; OKLCH L 56.7% C 0.226 H 307.1°. Best body text is #FFFFFF at 5.08:1 contrast (WCAG AA passes).

Color values

HEX#9A40DB
RGBrgb(154, 64, 219)
HSLhsl(275, 68%, 55%)
HSVhsv(275, 71%, 86%)
CMYKcmyk(29.7%, 70.8%, 0%, 14.1%)
CIE-LABlab(46.51, 63.01, -63.63)
CIE-LCHlch(46.51, 89.55, 314.72°)
OKLaboklab(56.69% 0.1364 -0.1806)
OKLCHoklch(56.69% 0.226 307.1)
XYZxyz(27.9433, 15.6516, 68.5531)
Luminance0.1565 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#9A40DB #81DB40
analogous
#4C40DB #9A40DB #DB40CE
triadic
#9A40DB #DB9A40 #40DB9A
tetradic
#9A40DB #DB4C40 #81DB40 #40CEDB
square
#9A40DB #DB4C40 #81DB40 #40CEDB
split-complementary
#9A40DB #CEDB40 #40DB4C
monochromatic
#591987 #7B23BB #9A40DB #B573E5 #D0A7EE

Accessibility & contrast

On white

5.08
#9A40DB on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.13
#9A40DB on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #9A40DB
5.08:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##9A40DB#FFFFFF#000000##FFFFFF
##9A40DB1.005.084.135.08
#FFFFFF5.081.0021.001.00
#0000004.1321.001.0021.00
##FFFFFF5.081.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006BDF
Deuteranopia (green-blind)
#046FD8
Tritanopia (blue-blind)
#8F648A
Achromatopsia (no color)
#6E6E6E

Design tokens & code

CSS
--color: #9a40db;
/* rgb */ color: rgb(154, 64, 219);
/* oklch */ color: oklch(56.7% 0.226 307.1);
Tailwind
colors: {
  custom: {
    50: '#bd7ce7',
    500: '#9a40db',
    950: '#000000',
  },
}
SCSS
$custom: #9a40db;
$custom-light: #bd7ce7;
$custom-dark: #000000;
JSON
{
  "hex": "#9a40db",
  "rgb": {
    "r": 154,
    "g": 64,
    "b": 219
  },
  "hsl": {
    "h": 274.839,
    "s": 68.282,
    "l": 55.49
  },
  "oklch": {
    "l": 0.56692,
    "c": 0.22634,
    "h": 307.1
  },
  "luminance": 0.15651
}

Semantic roles & 50–950 ramp

primary
#9A40DB
secondary
#B6DC9B
accent
#EB3D86
background
#FCF7FE
surface
#F8EEFD
border
#D1C9D5
text
#130A16
muted
#827C84

Preview Lab

Preview with #9A40DB

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

Preview Lab → · Contrast checker → · Palette generator →

#9A40DB Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva