#7F31C8#7F31C8

#7F31C8 is a mid, highly saturated violet. Relative luminance 0.109; OKLCH L 50.4% C 0.218 H 302.5°. Best body text is #FFFFFF at 6.61:1 contrast (WCAG AA passes).

Color values

HEX#7F31C8
RGBrgb(127, 49, 200)
HSLhsl(271, 61%, 49%)
HSVhsv(271, 76%, 78%)
CMYKcmyk(36.5%, 75.5%, 0%, 21.6%)
CIE-LABlab(39.38, 60.06, -64.44)
CIE-LCHlch(39.38, 88.09, 312.98°)
OKLaboklab(50.45% 0.1173 -0.1838)
OKLCHoklch(50.45% 0.218 302.5)
XYZxyz(20.2735, 10.8787, 55.6641)
Luminance0.1088 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7F31C8 #7AC831
analogous
#3331C8 #7F31C8 #C831C6
triadic
#7F31C8 #C87F31 #31C87F
tetradic
#7F31C8 #C83331 #7AC831 #31C6C8
square
#7F31C8 #C83331 #7AC831 #31C6C8
split-complementary
#7F31C8 #C6C831 #31C833
monochromatic
#411966 #602597 #7F31C8 #9D5FD8 #BB90E4

Accessibility & contrast

On white

6.61
#7F31C8 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.18
#7F31C8 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7F31C8
6.61:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7F31C8#FFFFFF#000000##FFFFFF
##7F31C81.006.613.186.61
#FFFFFF6.611.0021.001.00
#0000003.1821.001.0021.00
##FFFFFF6.611.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005BCC
Deuteranopia (green-blind)
#005CC5
Tritanopia (blue-blind)
#70587B
Achromatopsia (no color)
#5D5D5D

Design tokens & code

CSS
--color: #7f31c8;
/* rgb */ color: rgb(127, 49, 200);
/* oklch */ color: oklch(50.4% 0.218 302.5);
Tailwind
colors: {
  custom: {
    50: '#aa71da',
    500: '#7f31c8',
    950: '#000000',
  },
}
SCSS
$custom: #7f31c8;
$custom-light: #aa71da;
$custom-dark: #000000;
JSON
{
  "hex": "#7f31c8",
  "rgb": {
    "r": 127,
    "g": 49,
    "b": 200
  },
  "hsl": {
    "h": 270.993,
    "s": 60.643,
    "l": 48.824
  },
  "oklch": {
    "l": 0.50449,
    "c": 0.21805,
    "h": 302.5
  },
  "luminance": 0.10879
}

Semantic roles & 50–950 ramp

primary
#7F31C8
secondary
#A9CE86
accent
#E44491
background
#FBF7FD
surface
#F6EDFB
border
#D0C8D4
text
#110815
muted
#807B83

Preview Lab

Preview with #7F31C8

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

Preview Lab → · Contrast checker → · Palette generator →

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