#7F40C3#7F40C3

#7F40C3 is a mid, vivid violet. Relative luminance 0.121; OKLCH L 51.8% C 0.195 H 302.0°. Best body text is #FFFFFF at 6.13:1 contrast (WCAG AA passes).

Color values

HEX#7F40C3
RGBrgb(127, 64, 195)
HSLhsl(269, 52%, 51%)
HSVhsv(269, 67%, 76%)
CMYKcmyk(34.9%, 67.2%, 0%, 23.5%)
CIE-LABlab(41.40, 52.10, -58.24)
CIE-LCHlch(41.40, 78.14, 311.82°)
OKLaboklab(51.77% 0.1035 -0.1656)
OKLCHoklch(51.77% 0.195 302)
XYZxyz(20.4338, 12.1189, 52.8818)
Luminance0.1212 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7F40C3 #84C340
analogous
#4042C3 #7F40C3 #C040C3
triadic
#7F40C3 #C37F40 #40C37F
tetradic
#7F40C3 #C34042 #84C340 #40C3C0
square
#7F40C3 #C34042 #84C340 #40C3C0
split-complementary
#7F40C3 #C3C040 #42C340
monochromatic
#432168 #612F97 #7F40C3 #9E6FD2 #BD9DE0

Accessibility & contrast

On white

6.13
#7F40C3 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.42
#7F40C3 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7F40C3
6.13:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7F40C3#FFFFFF#000000##FFFFFF
##7F40C31.006.133.426.13
#FFFFFF6.131.0021.001.00
#0000003.4221.001.0021.00
##FFFFFF6.131.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0061C7
Deuteranopia (green-blind)
#0061C0
Tritanopia (blue-blind)
#715E7C
Achromatopsia (no color)
#626262

Design tokens & code

CSS
--color: #7f40c3;
/* rgb */ color: rgb(127, 64, 195);
/* oklch */ color: oklch(51.8% 0.195 302.0);
Tailwind
colors: {
  custom: {
    50: '#a979d6',
    500: '#7f40c3',
    950: '#000000',
  },
}
SCSS
$custom: #7f40c3;
$custom-light: #a979d6;
$custom-dark: #000000;
JSON
{
  "hex": "#7f40c3",
  "rgb": {
    "r": 127,
    "g": 64,
    "b": 195
  },
  "hsl": {
    "h": 268.855,
    "s": 52.191,
    "l": 50.784
  },
  "oklch": {
    "l": 0.51772,
    "c": 0.19535,
    "h": 302
  },
  "luminance": 0.12119
}

Semantic roles & 50–950 ramp

primary
#7F40C3
secondary
#B1CC92
accent
#DC4C97
background
#FAF7FD
surface
#F4EEFA
border
#CEC9D3
text
#100914
muted
#7F7B83

Preview Lab

Preview with #7F40C3

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

Preview Lab → · Contrast checker → · Palette generator →

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