#7940B2#7940B2

#7940B2 is a mid, vivid violet. Relative luminance 0.109; OKLCH L 49.9% C 0.175 H 303.7°. Best body text is #FFFFFF at 6.58:1 contrast (WCAG AA passes).

Color values

HEX#7940B2
RGBrgb(121, 64, 178)
HSLhsl(270, 47%, 47%)
HSVhsv(270, 64%, 70%)
CMYKcmyk(32%, 64%, 0%, 30.2%)
CIE-LABlab(39.49, 46.63, -51.39)
CIE-LCHlch(39.49, 69.39, 312.22°)
OKLaboklab(49.86% 0.097 -0.1457)
OKLCHoklch(49.86% 0.175 303.7)
XYZxyz(17.7526, 10.9461, 43.2884)
Luminance0.1095 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7940B2 #79B240
analogous
#4040B2 #7940B2 #B240B2
triadic
#7940B2 #B27940 #40B279
tetradic
#7940B2 #B24040 #79B240 #40B2B2
square
#7940B2 #B24040 #79B240 #40B2B2
split-complementary
#7940B2 #B2B240 #40B240
monochromatic
#3C2058 #5A3085 #7940B2 #9867C8 #B694D8

Accessibility & contrast

On white

6.58
#7940B2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.19
#7940B2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7940B2
6.58:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7940B2#FFFFFF#000000##FFFFFF
##7940B21.006.583.196.58
#FFFFFF6.581.0021.001.00
#0000003.1921.001.0021.00
##FFFFFF6.581.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005CB6
Deuteranopia (green-blind)
#1E5DAF
Tritanopia (blue-blind)
#6E5873
Achromatopsia (no color)
#5D5D5D

Design tokens & code

CSS
--color: #7940b2;
/* rgb */ color: rgb(121, 64, 178);
/* oklch */ color: oklch(49.9% 0.175 303.7);
Tailwind
colors: {
  custom: {
    50: '#a478ca',
    500: '#7940b2',
    950: '#000000',
  },
}
SCSS
$custom: #7940b2;
$custom-light: #a478ca;
$custom-dark: #000000;
JSON
{
  "hex": "#7940b2",
  "rgb": {
    "r": 121,
    "g": 64,
    "b": 178
  },
  "hsl": {
    "h": 270,
    "s": 47.107,
    "l": 47.451
  },
  "oklch": {
    "l": 0.49856,
    "c": 0.17507,
    "h": 303.7
  },
  "luminance": 0.10946
}

Semantic roles & 50–950 ramp

primary
#7940B2
secondary
#A7C48A
accent
#D75194
background
#FAF7FC
surface
#F4EDF8
border
#CEC8D1
text
#100913
muted
#7F7B82

Preview Lab

Preview with #7940B2

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

Preview Lab → · Contrast checker → · Palette generator →

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