#5B40CE#5B40CE

#5B40CE is a mid, highly saturated violet. Relative luminance 0.103; OKLCH L 49.0% C 0.207 H 284.5°. Best body text is #FFFFFF at 6.84:1 contrast (WCAG AA passes).

Color values

HEX#5B40CE
RGBrgb(91, 64, 206)
HSLhsl(251, 59%, 53%)
HSVhsv(251, 69%, 81%)
CMYKcmyk(55.8%, 68.9%, 0%, 19.2%)
CIE-LABlab(38.46, 48.55, -69.59)
CIE-LCHlch(38.46, 84.85, 304.90°)
OKLaboklab(49.05% 0.0518 -0.2002)
OKLCHoklch(49.05% 0.207 284.5)
XYZxyz(17.2850, 10.3461, 59.4667)
Luminance0.1035 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B40CE #B3CE40
analogous
#406CCE #5B40CE #A240CE
triadic
#5B40CE #CE5B40 #40CE5B
tetradic
#5B40CE #CE406C #B3CE40 #40CEA2
square
#5B40CE #CE406C #B3CE40 #40CEA2
split-complementary
#5B40CE #CEA240 #6CCE40
monochromatic
#2F1E75 #422BA6 #5B40CE #8571DA #AFA1E7

Accessibility & contrast

On white

6.84
#5B40CE on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.07
#5B40CE on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5B40CE
6.84:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B40CE#FFFFFF#000000##FFFFFF
##5B40CE1.006.843.076.84
#FFFFFF6.841.0021.001.00
#0000003.0721.001.0021.00
##FFFFFF6.841.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005FD2
Deuteranopia (green-blind)
#0056CB
Tritanopia (blue-blind)
#236582
Achromatopsia (no color)
#5B5B5B

Design tokens & code

CSS
--color: #5b40ce;
/* rgb */ color: rgb(91, 64, 206);
/* oklch */ color: oklch(49.0% 0.207 284.5);
Tailwind
colors: {
  custom: {
    50: '#9577de',
    500: '#5b40ce',
    950: '#000000',
  },
}
SCSS
$custom: #5b40ce;
$custom-light: #9577de;
$custom-dark: #000000;
JSON
{
  "hex": "#5b40ce",
  "rgb": {
    "r": 91,
    "g": 64,
    "b": 206
  },
  "hsl": {
    "h": 251.408,
    "s": 59.167,
    "l": 52.941
  },
  "oklch": {
    "l": 0.49048,
    "c": 0.2068,
    "h": 284.5
  },
  "luminance": 0.10347
}

Semantic roles & 50–950 ramp

primary
#5B40CE
secondary
#C8D496
accent
#E245C5
background
#F9F7FD
surface
#F2EDFB
border
#CCC8D4
text
#0E0915
muted
#7E7B83

Preview Lab

Preview with #5B40CE

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

Preview Lab → · Contrast checker → · Palette generator →

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