#7C40C2#7C40C2

#7C40C2 is a mid, vivid violet. Relative luminance 0.118; OKLCH L 51.4% C 0.194 H 300.9°. Best body text is #FFFFFF at 6.23:1 contrast (WCAG AA passes).

Color values

HEX#7C40C2
RGBrgb(124, 64, 194)
HSLhsl(268, 52%, 51%)
HSVhsv(268, 67%, 76%)
CMYKcmyk(36.1%, 67%, 0%, 23.9%)
CIE-LABlab(40.97, 51.24, -58.37)
CIE-LCHlch(40.97, 77.67, 311.28°)
OKLaboklab(51.36% 0.0996 -0.1661)
OKLCHoklch(51.36% 0.194 300.9)
XYZxyz(19.8808, 11.8468, 52.2677)
Luminance0.1185 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7C40C2 #86C240
analogous
#4045C2 #7C40C2 #BD40C2
triadic
#7C40C2 #C27C40 #40C27C
tetradic
#7C40C2 #C24045 #86C240 #40C2BD
square
#7C40C2 #C24045 #86C240 #40C2BD
split-complementary
#7C40C2 #C2BD40 #45C240
monochromatic
#412167 #5E3095 #7C40C2 #9C6ED1 #BC9DE0

Accessibility & contrast

On white

6.23
#7C40C2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.37
#7C40C2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7C40C2
6.23:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7C40C2#FFFFFF#000000##FFFFFF
##7C40C21.006.233.376.23
#FFFFFF6.231.0021.001.00
#0000003.3721.001.0021.00
##FFFFFF6.231.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0060C6
Deuteranopia (green-blind)
#0060BF
Tritanopia (blue-blind)
#6D5E7C
Achromatopsia (no color)
#616161

Design tokens & code

CSS
--color: #7c40c2;
/* rgb */ color: rgb(124, 64, 194);
/* oklch */ color: oklch(51.4% 0.194 300.9);
Tailwind
colors: {
  custom: {
    50: '#a779d5',
    500: '#7c40c2',
    950: '#000000',
  },
}
SCSS
$custom: #7c40c2;
$custom-light: #a779d5;
$custom-dark: #000000;
JSON
{
  "hex": "#7c40c2",
  "rgb": {
    "r": 124,
    "g": 64,
    "b": 194
  },
  "hsl": {
    "h": 267.692,
    "s": 51.587,
    "l": 50.588
  },
  "oklch": {
    "l": 0.51359,
    "c": 0.19369,
    "h": 300.9
  },
  "luminance": 0.11847
}

Semantic roles & 50–950 ramp

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

Preview Lab

Preview with #7C40C2

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

Preview Lab → · Contrast checker → · Palette generator →

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