#5C40D3#5C40D3

#5C40D3 is a mid, highly saturated violet. Relative luminance 0.106; OKLCH L 49.6% C 0.213 H 284.2°. Best body text is #FFFFFF at 6.71:1 contrast (WCAG AA passes).

Color values

HEX#5C40D3
RGBrgb(92, 64, 211)
HSLhsl(251, 63%, 54%)
HSVhsv(251, 70%, 83%)
CMYKcmyk(56.4%, 69.7%, 0%, 17.3%)
CIE-LABlab(38.97, 50.18, -71.63)
CIE-LCHlch(38.97, 87.45, 305.01°)
OKLaboklab(49.57% 0.0523 -0.2061)
OKLCHoklch(49.57% 0.213 284.2)
XYZxyz(18.0013, 10.6442, 62.7214)
Luminance0.1065 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5C40D3 #B7D340
analogous
#406ED3 #5C40D3 #A640D3
triadic
#5C40D3 #D35C40 #40D35C
tetradic
#5C40D3 #D3406E #B7D340 #40D3A6
square
#5C40D3 #D3406E #B7D340 #40D3A6
split-complementary
#5C40D3 #D3A640 #6ED340
monochromatic
#2F1D7C #4228AE #5C40D3 #8672DE #B1A3EA

Accessibility & contrast

On white

6.71
#5C40D3 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.13
#5C40D3 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5C40D3
6.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5C40D3#FFFFFF#000000##FFFFFF
##5C40D31.006.713.136.71
#FFFFFF6.711.0021.001.00
#0000003.1321.001.0021.00
##FFFFFF6.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0060D7
Deuteranopia (green-blind)
#0057D0
Tritanopia (blue-blind)
#1F6785
Achromatopsia (no color)
#5C5C5C

Design tokens & code

CSS
--color: #5c40d3;
/* rgb */ color: rgb(92, 64, 211);
/* oklch */ color: oklch(49.6% 0.213 284.2);
Tailwind
colors: {
  custom: {
    50: '#9677e2',
    500: '#5c40d3',
    950: '#000000',
  },
}
SCSS
$custom: #5c40d3;
$custom-light: #9677e2;
$custom-dark: #000000;
JSON
{
  "hex": "#5c40d3",
  "rgb": {
    "r": 92,
    "g": 64,
    "b": 211
  },
  "hsl": {
    "h": 251.429,
    "s": 62.553,
    "l": 53.922
  },
  "oklch": {
    "l": 0.49572,
    "c": 0.21268,
    "h": 284.2
  },
  "luminance": 0.10645
}

Semantic roles & 50–950 ramp

primary
#5C40D3
secondary
#CBD798
accent
#E642C6
background
#F9F7FE
surface
#F2EDFC
border
#CCC8D5
text
#0F0915
muted
#7E7B84

Preview Lab

Preview with #5C40D3

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

Preview Lab → · Contrast checker → · Palette generator →

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