#5940BB#5940BB

#5940BB is a mid, vivid violet. Relative luminance 0.094; OKLCH L 47.3% C 0.184 H 286.4°. Best body text is #FFFFFF at 7.30:1 contrast (WCAG AA passes).

Color values

HEX#5940BB
RGBrgb(89, 64, 187)
HSLhsl(252, 49%, 49%)
HSVhsv(252, 66%, 73%)
CMYKcmyk(52.4%, 65.8%, 0%, 26.7%)
CIE-LABlab(36.70, 42.56, -61.38)
CIE-LCHlch(36.70, 74.69, 304.74°)
OKLaboklab(47.26% 0.0518 -0.1762)
OKLCHoklch(47.26% 0.184 286.4)
XYZxyz(14.9202, 9.3777, 48.0280)
Luminance0.0938 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5940BB #A2BB40
analogous
#4065BB #5940BB #9740BB
triadic
#5940BB #BB5940 #40BB59
tetradic
#5940BB #BB4065 #A2BB40 #40BB97
square
#5940BB #BB4065 #A2BB40 #40BB97
split-complementary
#5940BB #BB9740 #65BB40
monochromatic
#2E2160 #43308D #5940BB #7F6CCD #A799DC

Accessibility & contrast

On white

7.30
#5940BB on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.88
#5940BB on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5940BB
7.30:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5940BB#FFFFFF#000000##FFFFFF
##5940BB1.007.302.887.30
#FFFFFF7.301.0021.001.00
#0000002.8821.001.0021.00
##FFFFFF7.301.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0059BF
Deuteranopia (green-blind)
#0053B9
Tritanopia (blue-blind)
#335F78
Achromatopsia (no color)
#565656

Design tokens & code

CSS
--color: #5940bb;
/* rgb */ color: rgb(89, 64, 187);
/* oklch */ color: oklch(47.3% 0.184 286.4);
Tailwind
colors: {
  custom: {
    50: '#9176d0',
    500: '#5940bb',
    950: '#000000',
  },
}
SCSS
$custom: #5940bb;
$custom-light: #9176d0;
$custom-dark: #000000;
JSON
{
  "hex": "#5940bb",
  "rgb": {
    "r": 89,
    "g": 64,
    "b": 187
  },
  "hsl": {
    "h": 252.195,
    "s": 49.004,
    "l": 49.216
  },
  "oklch": {
    "l": 0.47255,
    "c": 0.18364,
    "h": 286.4
  },
  "luminance": 0.09378
}

Semantic roles & 50–950 ramp

primary
#5940BB
secondary
#BCC88F
accent
#D94FBD
background
#F9F7FC
surface
#F2EDF9
border
#CCC8D2
text
#0E0914
muted
#7E7B82

Preview Lab

Preview with #5940BB

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

Preview Lab → · Contrast checker → · Palette generator →

#5940BB Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva