#7E31A3#7E31A3

#7E31A3 is a mid, vivid purple. Relative luminance 0.093; OKLCH L 47.5% C 0.181 H 312.5°. Best body text is #FFFFFF at 7.35:1 contrast (WCAG AA passes).

Color values

HEX#7E31A3
RGBrgb(126, 49, 163)
HSLhsl(281, 54%, 42%)
HSVhsv(281, 70%, 64%)
CMYKcmyk(22.7%, 69.9%, 0%, 36.1%)
CIE-LABlab(36.51, 51.52, -47.21)
CIE-LCHlch(36.51, 69.88, 317.50°)
OKLaboklab(47.53% 0.1222 -0.1332)
OKLCHoklch(47.53% 0.181 312.5)
XYZxyz(16.3122, 9.2770, 35.5746)
Luminance0.0928 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7E31A3 #56A331
analogous
#4531A3 #7E31A3 #A3318F
triadic
#7E31A3 #A37E31 #31A37E
tetradic
#7E31A3 #A34531 #56A331 #318FA3
square
#7E31A3 #A34531 #56A331 #318FA3
split-complementary
#7E31A3 #8FA331 #31A345
monochromatic
#351545 #5A2374 #7E31A3 #9F49C8 #B878D6

Accessibility & contrast

On white

7.35
#7E31A3 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.86
#7E31A3 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #7E31A3
7.35:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7E31A3#FFFFFF#000000##FFFFFF
##7E31A31.007.352.867.35
#FFFFFF7.351.0021.001.00
#0000002.8621.001.0021.00
##FFFFFF7.351.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0052A6
Deuteranopia (green-blind)
#2658A0
Tritanopia (blue-blind)
#7A4966
Achromatopsia (no color)
#565656

Design tokens & code

CSS
--color: #7e31a3;
/* rgb */ color: rgb(126, 49, 163);
/* oklch */ color: oklch(47.5% 0.181 312.5);
Tailwind
colors: {
  custom: {
    50: '#a770bf',
    500: '#7e31a3',
    950: '#000000',
  },
}
SCSS
$custom: #7e31a3;
$custom-light: #a770bf;
$custom-dark: #000000;
JSON
{
  "hex": "#7e31a3",
  "rgb": {
    "r": 126,
    "g": 49,
    "b": 163
  },
  "hsl": {
    "h": 280.526,
    "s": 53.774,
    "l": 41.569
  },
  "oklch": {
    "l": 0.47534,
    "c": 0.1808,
    "h": 312.5
  },
  "luminance": 0.09277
}

Semantic roles & 50–950 ramp

primary
#7E31A3
secondary
#8ABF71
accent
#DD4B7A
background
#FAF7FB
surface
#F4EDF7
border
#CEC8D0
text
#100812
muted
#7F7B81

Preview Lab

Preview with #7E31A3

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

Preview Lab → · Contrast checker → · Palette generator →

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