#5D40D8#5D40D8

#5D40D8 is a mid, highly saturated violet. Relative luminance 0.110; OKLCH L 50.1% C 0.218 H 284.0°. Best body text is #FFFFFF at 6.58:1 contrast (WCAG AA passes).

Color values

HEX#5D40D8
RGBrgb(93, 64, 216)
HSLhsl(251, 66%, 55%)
HSVhsv(251, 70%, 85%)
CMYKcmyk(56.9%, 70.4%, 0%, 15.3%)
CIE-LABlab(39.50, 51.79, -73.64)
CIE-LCHlch(39.50, 90.03, 305.12°)
OKLaboklab(50.1% 0.0528 -0.212)
OKLCHoklch(50.1% 0.218 284)
XYZxyz(18.7385, 10.9507, 66.0787)
Luminance0.1095 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5D40D8 #BBD840
analogous
#406FD8 #5D40D8 #A940D8
triadic
#5D40D8 #D85D40 #40D85D
tetradic
#5D40D8 #D8406F #BBD840 #40D8A9
square
#5D40D8 #D8406F #BBD840 #40D8A9
split-complementary
#5D40D8 #D8A940 #6FD840
monochromatic
#2F1B83 #4125B6 #5D40D8 #8873E2 #B3A6ED

Accessibility & contrast

On white

6.58
#5D40D8 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.19
#5D40D8 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5D40D8
6.58:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5D40D8#FFFFFF#000000##FFFFFF
##5D40D81.006.583.196.58
#FFFFFF6.581.0021.001.00
#0000003.1921.001.0021.00
##FFFFFF6.581.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0062DD
Deuteranopia (green-blind)
#0058D5
Tritanopia (blue-blind)
#1B6988
Achromatopsia (no color)
#5D5D5D

Design tokens & code

CSS
--color: #5d40d8;
/* rgb */ color: rgb(93, 64, 216);
/* oklch */ color: oklch(50.1% 0.218 284.0);
Tailwind
colors: {
  custom: {
    50: '#9778e5',
    500: '#5d40d8',
    950: '#000000',
  },
}
SCSS
$custom: #5d40d8;
$custom-light: #9778e5;
$custom-dark: #000000;
JSON
{
  "hex": "#5d40d8",
  "rgb": {
    "r": 93,
    "g": 64,
    "b": 216
  },
  "hsl": {
    "h": 251.447,
    "s": 66.087,
    "l": 54.902
  },
  "oklch": {
    "l": 0.50099,
    "c": 0.21848,
    "h": 284
  },
  "luminance": 0.10952
}

Semantic roles & 50–950 ramp

primary
#5D40D8
secondary
#CEDA9A
accent
#E93FC9
background
#FAF7FE
surface
#F3EDFC
border
#CDC8D5
text
#0F0916
muted
#7F7B84

Preview Lab

Preview with #5D40D8

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

Preview Lab → · Contrast checker → · Palette generator →

#5D40D8 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva