#7940D4#7940D4

#7940D4 is a mid, highly saturated violet. Relative luminance 0.125; OKLCH L 52.4% C 0.213 H 295.7°. Best body text is #FFFFFF at 6.01:1 contrast (WCAG AA passes).

Color values

HEX#7940D4
RGBrgb(121, 64, 212)
HSLhsl(263, 63%, 54%)
HSVhsv(263, 70%, 83%)
CMYKcmyk(42.9%, 69.8%, 0%, 16.9%)
CIE-LABlab(41.98, 55.22, -67.18)
CIE-LCHlch(41.98, 86.96, 309.42°)
OKLaboklab(52.42% 0.0927 -0.1921)
OKLCHoklch(52.42% 0.213 295.7)
XYZxyz(21.5991, 12.4847, 63.5464)
Luminance0.1249 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7940D4 #9BD440
analogous
#4051D4 #7940D4 #C340D4
triadic
#7940D4 #D47940 #40D479
tetradic
#7940D4 #D44051 #9BD440 #40D4C3
square
#7940D4 #D44051 #9BD440 #40D4C3
split-complementary
#7940D4 #D4C340 #51D440
monochromatic
#421C7D #5C27AF #7940D4 #9C72DF #BFA4EA

Accessibility & contrast

On white

6.01
#7940D4 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.50
#7940D4 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7940D4
6.01:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7940D4#FFFFFF#000000##FFFFFF
##7940D41.006.013.506.01
#FFFFFF6.011.0021.001.00
#0000003.5021.001.0021.00
##FFFFFF6.011.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0064D8
Deuteranopia (green-blind)
#0061D1
Tritanopia (blue-blind)
#616585
Achromatopsia (no color)
#636363

Design tokens & code

CSS
--color: #7940d4;
/* rgb */ color: rgb(121, 64, 212);
/* oklch */ color: oklch(52.4% 0.213 295.7);
Tailwind
colors: {
  custom: {
    50: '#a779e2',
    500: '#7940d4',
    950: '#000000',
  },
}
SCSS
$custom: #7940d4;
$custom-light: #a779e2;
$custom-dark: #000000;
JSON
{
  "hex": "#7940d4",
  "rgb": {
    "r": 121,
    "g": 64,
    "b": 212
  },
  "hsl": {
    "h": 263.108,
    "s": 63.248,
    "l": 54.118
  },
  "oklch": {
    "l": 0.52422,
    "c": 0.21331,
    "h": 295.7
  },
  "luminance": 0.12485
}

Semantic roles & 50–950 ramp

primary
#7940D4
secondary
#BFD798
accent
#E642A7
background
#FAF7FE
surface
#F4EEFC
border
#CEC9D5
text
#100915
muted
#7F7B84

Preview Lab

Preview with #7940D4

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

Preview Lab → · Contrast checker → · Palette generator →

#7940D4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva