#7E31AC#7E31AC

#7E31AC is a mid, vivid violet. Relative luminance 0.096; OKLCH L 48.2% C 0.190 H 309.7°. Best body text is #FFFFFF at 7.19:1 contrast (WCAG AA passes).

Color values

HEX#7E31AC
RGBrgb(126, 49, 172)
HSLhsl(278, 56%, 43%)
HSVhsv(278, 72%, 67%)
CMYKcmyk(26.7%, 71.5%, 0%, 32.5%)
CIE-LABlab(37.14, 53.49, -51.60)
CIE-LCHlch(37.14, 74.32, 316.03°)
OKLaboklab(48.18% 0.1212 -0.1461)
OKLCHoklch(48.18% 0.19 309.7)
XYZxyz(17.1474, 9.6111, 39.9735)
Luminance0.0961 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7E31AC #5FAC31
analogous
#4031AC #7E31AC #AC319C
triadic
#7E31AC #AC7E31 #31AC7E
tetradic
#7E31AC #AC4031 #5FAC31 #319CAC
square
#7E31AC #AC4031 #5FAC31 #319CAC
split-complementary
#7E31AC #9CAC31 #31AC40
monochromatic
#38164D #5B237C #7E31AC #9D4ECC #B77DDA

Accessibility & contrast

On white

7.19
#7E31AC on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.92
#7E31AC on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #7E31AC
7.19:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7E31AC#FFFFFF#000000##FFFFFF
##7E31AC1.007.192.927.19
#FFFFFF7.191.0021.001.00
#0000002.9221.001.0021.00
##FFFFFF7.191.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0054B0
Deuteranopia (green-blind)
#1858A9
Tritanopia (blue-blind)
#774C6B
Achromatopsia (no color)
#575757

Design tokens & code

CSS
--color: #7e31ac;
/* rgb */ color: rgb(126, 49, 172);
/* oklch */ color: oklch(48.2% 0.190 309.7);
Tailwind
colors: {
  custom: {
    50: '#a870c5',
    500: '#7e31ac',
    950: '#000000',
  },
}
SCSS
$custom: #7e31ac;
$custom-light: #a870c5;
$custom-dark: #000000;
JSON
{
  "hex": "#7e31ac",
  "rgb": {
    "r": 126,
    "g": 49,
    "b": 172
  },
  "hsl": {
    "h": 277.561,
    "s": 55.656,
    "l": 43.333
  },
  "oklch": {
    "l": 0.48177,
    "c": 0.1898,
    "h": 309.7
  },
  "luminance": 0.09611
}

Semantic roles & 50–950 ramp

primary
#7E31AC
secondary
#93C376
accent
#DF4981
background
#FAF7FC
surface
#F4EDF8
border
#CEC8D1
text
#100813
muted
#7F7B82

Preview Lab

Preview with #7E31AC

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

Preview Lab → · Contrast checker → · Palette generator →

#7E31AC Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva