#5E31B8#5E31B8

#5E31B8 is a mid, vivid violet. Relative luminance 0.080; OKLCH L 45.4% C 0.197 H 291.8°. Best body text is #FFFFFF at 8.05:1 contrast (WCAG AA passes).

Color values

HEX#5E31B8
RGBrgb(94, 49, 184)
HSLhsl(260, 58%, 46%)
HSVhsv(260, 73%, 72%)
CMYKcmyk(48.9%, 73.4%, 0%, 27.8%)
CIE-LABlab(34.06, 50.55, -63.91)
CIE-LCHlch(34.06, 81.49, 308.35°)
OKLaboklab(45.41% 0.0733 -0.1834)
OKLCHoklch(45.41% 0.197 291.8)
XYZxyz(14.3637, 8.0365, 46.1325)
Luminance0.0804 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5E31B8 #8BB831
analogous
#3147B8 #5E31B8 #A131B8
triadic
#5E31B8 #B85E31 #31B85E
tetradic
#5E31B8 #B83147 #8BB831 #31B8A1
square
#5E31B8 #B83147 #8BB831 #31B8A1
split-complementary
#5E31B8 #B8A131 #47B831
monochromatic
#2D1757 #452488 #5E31B8 #7E55D2 #A385DE

Accessibility & contrast

On white

8.05
#5E31B8 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.61
#5E31B8 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5E31B8
8.05:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5E31B8#FFFFFF#000000##FFFFFF
##5E31B81.008.052.618.05
#FFFFFF8.051.0021.001.00
#0000002.6121.001.0021.00
##FFFFFF8.051.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0052BC
Deuteranopia (green-blind)
#004DB5
Tritanopia (blue-blind)
#415572
Achromatopsia (no color)
#505050

Design tokens & code

CSS
--color: #5e31b8;
/* rgb */ color: rgb(94, 49, 184);
/* oklch */ color: oklch(45.4% 0.197 291.8);
Tailwind
colors: {
  custom: {
    50: '#946dce',
    500: '#5e31b8',
    950: '#000000',
  },
}
SCSS
$custom: #5e31b8;
$custom-light: #946dce;
$custom-dark: #000000;
JSON
{
  "hex": "#5e31b8",
  "rgb": {
    "r": 94,
    "g": 49,
    "b": 184
  },
  "hsl": {
    "h": 260,
    "s": 57.94,
    "l": 45.686
  },
  "oklch": {
    "l": 0.45408,
    "c": 0.19749,
    "h": 291.8
  },
  "luminance": 0.08037
}

Semantic roles & 50–950 ramp

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

Preview Lab

Preview with #5E31B8

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

Preview Lab → · Contrast checker → · Palette generator →

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