#7940BA#7940BA

#7940BA is a mid, vivid violet. Relative luminance 0.113; OKLCH L 50.4% C 0.184 H 301.5°. Best body text is #FFFFFF at 6.45:1 contrast (WCAG AA passes).

Color values

HEX#7940BA
RGBrgb(121, 64, 186)
HSLhsl(268, 49%, 49%)
HSVhsv(268, 66%, 73%)
CMYKcmyk(34.9%, 65.6%, 0%, 27.1%)
CIE-LABlab(40.04, 48.62, -55.21)
CIE-LCHlch(40.04, 73.56, 311.37°)
OKLaboklab(50.43% 0.0963 -0.157)
OKLCHoklch(50.43% 0.184 301.5)
XYZxyz(18.5794, 11.2768, 47.6427)
Luminance0.1128 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7940BA #81BA40
analogous
#4044BA #7940BA #B640BA
triadic
#7940BA #BA7940 #40BA79
tetradic
#7940BA #BA4044 #81BA40 #40BAB6
square
#7940BA #BA4044 #81BA40 #40BAB6
split-complementary
#7940BA #BAB640 #44BA40
monochromatic
#3E215F #5B308C #7940BA #986BCC #B899DC

Accessibility & contrast

On white

6.45
#7940BA on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.26
#7940BA on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7940BA
6.45:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7940BA#FFFFFF#000000##FFFFFF
##7940BA1.006.453.266.45
#FFFFFF6.451.0021.001.00
#0000003.2621.001.0021.00
##FFFFFF6.451.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005EBE
Deuteranopia (green-blind)
#085EB7
Tritanopia (blue-blind)
#6B5B77
Achromatopsia (no color)
#5E5E5E

Design tokens & code

CSS
--color: #7940ba;
/* rgb */ color: rgb(121, 64, 186);
/* oklch */ color: oklch(50.4% 0.184 301.5);
Tailwind
colors: {
  custom: {
    50: '#a478cf',
    500: '#7940ba',
    950: '#000000',
  },
}
SCSS
$custom: #7940ba;
$custom-light: #a478cf;
$custom-dark: #000000;
JSON
{
  "hex": "#7940ba",
  "rgb": {
    "r": 121,
    "g": 64,
    "b": 186
  },
  "hsl": {
    "h": 268.033,
    "s": 48.8,
    "l": 49.02
  },
  "oklch": {
    "l": 0.50431,
    "c": 0.18416,
    "h": 301.5
  },
  "luminance": 0.11277
}

Semantic roles & 50–950 ramp

primary
#7940BA
secondary
#ADC88E
accent
#D84F98
background
#FAF7FC
surface
#F4EDF9
border
#CEC8D2
text
#100914
muted
#7F7B82

Preview Lab

Preview with #7940BA

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

Preview Lab → · Contrast checker → · Palette generator →

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