#5D31B7#5D31B7

#5D31B7 is a mid, vivid violet. Relative luminance 0.079; OKLCH L 45.2% C 0.196 H 291.5°. Best body text is #FFFFFF at 8.11:1 contrast (WCAG AA passes).

Color values

HEX#5D31B7
RGBrgb(93, 49, 183)
HSLhsl(260, 58%, 45%)
HSVhsv(260, 73%, 72%)
CMYKcmyk(49.2%, 73.2%, 0%, 28.2%)
CIE-LABlab(33.86, 50.12, -63.64)
CIE-LCHlch(33.86, 81.01, 308.22°)
OKLaboklab(45.22% 0.0721 -0.1826)
OKLCHoklch(45.22% 0.196 291.5)
XYZxyz(14.1573, 7.9421, 45.5776)
Luminance0.0794 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5D31B7 #8BB731
analogous
#3148B7 #5D31B7 #A031B7
triadic
#5D31B7 #B75D31 #31B75D
tetradic
#5D31B7 #B73148 #8BB731 #31B7A0
square
#5D31B7 #B73148 #8BB731 #31B7A0
split-complementary
#5D31B7 #B7A031 #48B731
monochromatic
#2C1756 #442487 #5D31B7 #7D54D1 #A284DE

Accessibility & contrast

On white

8.11
#5D31B7 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.59
#5D31B7 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5D31B7
8.11:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5D31B7#FFFFFF#000000##FFFFFF
##5D31B71.008.112.598.11
#FFFFFF8.111.0021.001.00
#0000002.5921.001.0021.00
##FFFFFF8.111.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0052BB
Deuteranopia (green-blind)
#004DB4
Tritanopia (blue-blind)
#3F5571
Achromatopsia (no color)
#505050

Design tokens & code

CSS
--color: #5d31b7;
/* rgb */ color: rgb(93, 49, 183);
/* oklch */ color: oklch(45.2% 0.196 291.5);
Tailwind
colors: {
  custom: {
    50: '#946dce',
    500: '#5d31b7',
    950: '#000000',
  },
}
SCSS
$custom: #5d31b7;
$custom-light: #946dce;
$custom-dark: #000000;
JSON
{
  "hex": "#5d31b7",
  "rgb": {
    "r": 93,
    "g": 49,
    "b": 183
  },
  "hsl": {
    "h": 259.701,
    "s": 57.759,
    "l": 45.49
  },
  "oklch": {
    "l": 0.45217,
    "c": 0.19634,
    "h": 291.5
  },
  "luminance": 0.07943
}

Semantic roles & 50–950 ramp

primary
#5D31B7
secondary
#AFC87C
accent
#E147AE
background
#F9F6FC
surface
#F2ECF9
border
#CCC7D2
text
#0E0714
muted
#7E7A82

Preview Lab

Preview with #5D31B7

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

Preview Lab → · Contrast checker → · Palette generator →

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