#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 |
|---|---|
| RGB | rgb(121, 64, 178) |
| HSL | hsl(270, 47%, 47%) |
| HSV | hsv(270, 64%, 70%) |
| CMYK | cmyk(32%, 64%, 0%, 30.2%) |
| CIE-LAB | lab(39.49, 46.63, -51.39) |
| CIE-LCH | lch(39.49, 69.39, 312.22°) |
| OKLab | oklab(49.86% 0.097 -0.1457) |
| OKLCH | oklch(49.86% 0.175 303.7) |
| XYZ | xyz(17.7526, 10.9461, 43.2884) |
| Luminance | 0.1095 (WCAG relative) |
| Temperature | cool |
| Family | violet |
Closest named colors
Royal Purple
#7851A9
ΔE00 4.86
Rebeccapurple
#663399
ΔE00 5.68
Bluey Purple
#6241C7
ΔE00 5.71
Purply
#983FB2
ΔE00 6.29
Darkorchid
#9932CC
ΔE00 6.31
Blueviolet
#8A2BE2
ΔE00 7.15
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 |
|---|---|---|---|---|
| ##7940B2 | 1.00 | 6.58 | 3.19 | 6.58 |
| #FFFFFF | 6.58 | 1.00 | 21.00 | 1.00 |
| #000000 | 3.19 | 21.00 | 1.00 | 21.00 |
| ##FFFFFF | 6.58 | 1.00 | 21.00 | 1.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