#9A40D5#9A40D5

#9A40D5 is a mid, highly saturated violet. Relative luminance 0.153; OKLCH L 56.3% C 0.220 H 308.5°. Best body text is #FFFFFF at 5.16:1 contrast (WCAG AA passes).

Color values

HEX#9A40D5
RGBrgb(154, 64, 213)
HSLhsl(276, 64%, 54%)
HSVhsv(276, 70%, 84%)
CMYKcmyk(27.7%, 70%, 0%, 16.5%)
CIE-LABlab(46.10, 61.70, -60.88)
CIE-LCHlch(46.10, 86.67, 315.38°)
OKLaboklab(56.26% 0.1373 -0.1725)
OKLCHoklch(56.26% 0.22 308.5)
XYZxyz(27.1676, 15.3414, 64.4679)
Luminance0.1534 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#9A40D5 #7BD540
analogous
#5040D5 #9A40D5 #D540C5
triadic
#9A40D5 #D59A40 #40D59A
tetradic
#9A40D5 #D55040 #7BD540 #40C5D5
square
#9A40D5 #D55040 #7BD540 #40C5D5
split-complementary
#9A40D5 #C5D540 #40D550
monochromatic
#581C7F #7A27B1 #9A40D5 #B572E0 #CFA4EB

Accessibility & contrast

On white

5.16
#9A40D5 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.07
#9A40D5 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #9A40D5
5.16:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##9A40D5#FFFFFF#000000##FFFFFF
##9A40D51.005.164.075.16
#FFFFFF5.161.0021.001.00
#0000004.0721.001.0021.00
##FFFFFF5.161.0021.001.00

Color blindness preview

Protanopia (red-blind)
#006AD9
Deuteranopia (green-blind)
#1B6ED2
Tritanopia (blue-blind)
#916186
Achromatopsia (no color)
#6D6D6D

Design tokens & code

CSS
--color: #9a40d5;
/* rgb */ color: rgb(154, 64, 213);
/* oklch */ color: oklch(56.3% 0.220 308.5);
Tailwind
colors: {
  custom: {
    50: '#bd7ce3',
    500: '#9a40d5',
    950: '#000000',
  },
}
SCSS
$custom: #9a40d5;
$custom-light: #bd7ce3;
$custom-dark: #000000;
JSON
{
  "hex": "#9a40d5",
  "rgb": {
    "r": 154,
    "g": 64,
    "b": 213
  },
  "hsl": {
    "h": 276.242,
    "s": 63.948,
    "l": 54.314
  },
  "oklch": {
    "l": 0.56264,
    "c": 0.22047,
    "h": 308.5
  },
  "luminance": 0.15341
}

Semantic roles & 50–950 ramp

primary
#9A40D5
secondary
#B2D899
accent
#E74183
background
#FCF7FE
surface
#F8EEFC
border
#D1C9D5
text
#130A15
muted
#827C84

Preview Lab

Preview with #9A40D5

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

Preview Lab → · Contrast checker → · Palette generator →

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