#5F40D0#5F40D0

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

Color values

HEX#5F40D0
RGBrgb(95, 64, 208)
HSLhsl(253, 61%, 53%)
HSVhsv(253, 69%, 82%)
CMYKcmyk(54.3%, 69.2%, 0%, 18.4%)
CIE-LABlab(38.99, 49.76, -69.86)
CIE-LCHlch(38.99, 85.77, 305.46°)
OKLaboklab(49.57% 0.057 -0.2009)
OKLCHoklch(49.57% 0.209 285.8)
XYZxyz(17.9345, 10.6528, 60.7734)
Luminance0.1065 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5F40D0 #B1D040
analogous
#4069D0 #5F40D0 #A740D0
triadic
#5F40D0 #D05F40 #40D05F
tetradic
#5F40D0 #D04069 #B1D040 #40D0A7
square
#5F40D0 #D04069 #B1D040 #40D0A7
split-complementary
#5F40D0 #D0A740 #69D040
monochromatic
#311E78 #452AA9 #5F40D0 #8871DC #B1A2E8

Accessibility & contrast

On white

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

On black

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

Best text color

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

Contrast matrix

fg \ bg##5F40D0#FFFFFF#000000##FFFFFF
##5F40D01.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)
#0060D4
Deuteranopia (green-blind)
#0057CD
Tritanopia (blue-blind)
#2E6683
Achromatopsia (no color)
#5C5C5C

Design tokens & code

CSS
--color: #5f40d0;
/* rgb */ color: rgb(95, 64, 208);
/* oklch */ color: oklch(49.6% 0.209 285.8);
Tailwind
colors: {
  custom: {
    50: '#9777df',
    500: '#5f40d0',
    950: '#000000',
  },
}
SCSS
$custom: #5f40d0;
$custom-light: #9777df;
$custom-dark: #000000;
JSON
{
  "hex": "#5f40d0",
  "rgb": {
    "r": 95,
    "g": 64,
    "b": 208
  },
  "hsl": {
    "h": 252.917,
    "s": 60.504,
    "l": 53.333
  },
  "oklch": {
    "l": 0.49569,
    "c": 0.20879,
    "h": 285.8
  },
  "luminance": 0.10654
}

Semantic roles & 50–950 ramp

primary
#5F40D0
secondary
#C8D597
accent
#E444C1
background
#F9F7FD
surface
#F2EDFB
border
#CCC8D4
text
#0F0915
muted
#7E7B83

Preview Lab

Preview with #5F40D0

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

Preview Lab → · Contrast checker → · Palette generator →

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