#7E21D4#7E21D4

#7E21D4 is a mid, highly saturated violet. Relative luminance 0.103; OKLCH L 50.0% C 0.243 H 300.6°. Best body text is #FFFFFF at 6.87:1 contrast (WCAG AA passes).

Color values

HEX#7E21D4
RGBrgb(126, 33, 212)
HSLhsl(271, 73%, 48%)
HSVhsv(271, 84%, 83%)
CMYKcmyk(40.6%, 84.4%, 0%, 16.9%)
CIE-LABlab(38.33, 68.21, -73.11)
CIE-LCHlch(38.33, 99.99, 313.01°)
OKLaboklab(50.01% 0.1238 -0.2092)
OKLCHoklch(50.01% 0.243 300.6)
XYZxyz(21.0287, 10.2766, 63.1503)
Luminance0.1028 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7E21D4 #77D421
analogous
#2421D4 #7E21D4 #D421D0
triadic
#7E21D4 #D47E21 #21D47E
tetradic
#7E21D4 #D42421 #77D421 #21D0D4
square
#7E21D4 #D42421 #77D421 #21D0D4
split-complementary
#7E21D4 #D0D421 #21D424
monochromatic
#3F116A #5F199F #7E21D4 #9C4FE4 #BA84EC

Accessibility & contrast

On white

6.87
#7E21D4 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.06
#7E21D4 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7E21D4
6.87:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7E21D4#FFFFFF#000000##FFFFFF
##7E21D41.006.873.066.87
#FFFFFF6.871.0021.001.00
#0000003.0621.001.0021.00
##FFFFFF6.871.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005AD9
Deuteranopia (green-blind)
#0059D1
Tritanopia (blue-blind)
#6A577F
Achromatopsia (no color)
#5A5A5A

Design tokens & code

CSS
--color: #7e21d4;
/* rgb */ color: rgb(126, 33, 212);
/* oklch */ color: oklch(50.0% 0.243 300.6);
Tailwind
colors: {
  custom: {
    50: '#ac6be2',
    500: '#7e21d4',
    950: '#000000',
  },
}
SCSS
$custom: #7e21d4;
$custom-light: #ac6be2;
$custom-dark: #000000;
JSON
{
  "hex": "#7e21d4",
  "rgb": {
    "r": 126,
    "g": 33,
    "b": 212
  },
  "hsl": {
    "h": 271.173,
    "s": 73.061,
    "l": 48.039
  },
  "oklch": {
    "l": 0.50008,
    "c": 0.24307,
    "h": 300.6
  },
  "luminance": 0.10277
}

Semantic roles & 50–950 ramp

primary
#7E21D4
secondary
#A7D57C
accent
#F03890
background
#FBF6FE
surface
#F6ECFC
border
#D0C7D5
text
#110716
muted
#807A84

Preview Lab

Preview with #7E21D4

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

Preview Lab → · Contrast checker → · Palette generator →

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