#5B40DB#5B40DB

#5B40DB is a mid, highly saturated violet. Relative luminance 0.110; OKLCH L 50.2% C 0.222 H 282.9°. Best body text is #FFFFFF at 6.56:1 contrast (WCAG AA passes).

Color values

HEX#5B40DB
RGBrgb(91, 64, 219)
HSLhsl(250, 68%, 55%)
HSVhsv(250, 71%, 86%)
CMYKcmyk(58.4%, 70.8%, 0%, 14.1%)
CIE-LABlab(39.59, 52.39, -75.22)
CIE-LCHlch(39.59, 91.67, 304.86°)
OKLaboklab(50.2% 0.0494 -0.2167)
OKLCHoklch(50.2% 0.222 282.9)
XYZxyz(18.9300, 11.0042, 68.1306)
Luminance0.1100 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B40DB #C0DB40
analogous
#4072DB #5B40DB #A940DB
triadic
#5B40DB #DB5B40 #40DB5B
tetradic
#5B40DB #DB4072 #C0DB40 #40DBA9
square
#5B40DB #DB4072 #C0DB40 #40DBA9
split-complementary
#5B40DB #DBA940 #72DB40
monochromatic
#2D1987 #3E23BB #5B40DB #8773E5 #B3A7EE

Accessibility & contrast

On white

6.56
#5B40DB on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.20
#5B40DB on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5B40DB
6.56:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B40DB#FFFFFF#000000##FFFFFF
##5B40DB1.006.563.206.56
#FFFFFF6.561.0021.001.00
#0000003.2021.001.0021.00
##FFFFFF6.561.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0062E0
Deuteranopia (green-blind)
#0058D8
Tritanopia (blue-blind)
#036A89
Achromatopsia (no color)
#5D5D5D

Design tokens & code

CSS
--color: #5b40db;
/* rgb */ color: rgb(91, 64, 219);
/* oklch */ color: oklch(50.2% 0.222 282.9);
Tailwind
colors: {
  custom: {
    50: '#9778e7',
    500: '#5b40db',
    950: '#000000',
  },
}
SCSS
$custom: #5b40db;
$custom-light: #9778e7;
$custom-dark: #000000;
JSON
{
  "hex": "#5b40db",
  "rgb": {
    "r": 91,
    "g": 64,
    "b": 219
  },
  "hsl": {
    "h": 250.452,
    "s": 68.282,
    "l": 55.49
  },
  "oklch": {
    "l": 0.50201,
    "c": 0.22228,
    "h": 282.9
  },
  "luminance": 0.11005
}

Semantic roles & 50–950 ramp

primary
#5B40DB
secondary
#D0DC9B
accent
#EB3DCD
background
#FAF7FE
surface
#F3EDFD
border
#CDC8D5
text
#0F0916
muted
#7F7B84

Preview Lab

Preview with #5B40DB

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

Preview Lab → · Contrast checker → · Palette generator →

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