#5E40E1#5E40E1

#5E40E1 is a mid, highly saturated violet. Relative luminance 0.115; OKLCH L 51.0% C 0.229 H 283.2°. Best body text is #FFFFFF at 6.37:1 contrast (WCAG AA passes).

Color values

HEX#5E40E1
RGBrgb(94, 64, 225)
HSLhsl(251, 73%, 57%)
HSVhsv(251, 72%, 88%)
CMYKcmyk(58.2%, 71.6%, 0%, 11.8%)
CIE-LABlab(40.38, 54.56, -77.34)
CIE-LCHlch(40.38, 94.65, 305.20°)
OKLaboklab(50.99% 0.0523 -0.2228)
OKLCHoklch(50.99% 0.229 283.2)
XYZxyz(20.0359, 11.4814, 72.3799)
Luminance0.1148 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5E40E1 #C3E140
analogous
#4073E1 #5E40E1 #AF40E1
triadic
#5E40E1 #E15E40 #40E15E
tetradic
#5E40E1 #E14073 #C3E140 #40E1AF
square
#5E40E1 #E14073 #C3E140 #40E1AF
split-complementary
#5E40E1 #E1AF40 #73E140
monochromatic
#2D1790 #3E1FC5 #5E40E1 #8B75E9 #B7AAF2

Accessibility & contrast

On white

6.37
#5E40E1 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.30
#5E40E1 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5E40E1
6.37:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5E40E1#FFFFFF#000000##FFFFFF
##5E40E11.006.373.306.37
#FFFFFF6.371.0021.001.00
#0000003.3021.001.0021.00
##FFFFFF6.371.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0064E6
Deuteranopia (green-blind)
#005ADE
Tritanopia (blue-blind)
#076C8D
Achromatopsia (no color)
#5F5F5F

Design tokens & code

CSS
--color: #5e40e1;
/* rgb */ color: rgb(94, 64, 225);
/* oklch */ color: oklch(51.0% 0.229 283.2);
Tailwind
colors: {
  custom: {
    50: '#9978ec',
    500: '#5e40e1',
    950: '#000000',
  },
}
SCSS
$custom: #5e40e1;
$custom-light: #9978ec;
$custom-dark: #000000;
JSON
{
  "hex": "#5e40e1",
  "rgb": {
    "r": 94,
    "g": 64,
    "b": 225
  },
  "hsl": {
    "h": 251.18,
    "s": 72.851,
    "l": 56.667
  },
  "oklch": {
    "l": 0.50991,
    "c": 0.22888,
    "h": 283.2
  },
  "luminance": 0.11483
}

Semantic roles & 50–950 ramp

primary
#5E40E1
secondary
#D3DF9D
accent
#F038CD
background
#FAF7FE
surface
#F4EDFD
border
#CEC8D5
text
#0F0916
muted
#7F7B84

Preview Lab

Preview with #5E40E1

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

Preview Lab → · Contrast checker → · Palette generator →

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