Blueviolet — #8A2BE2
#8A2BE2 is a medium, vivid violet. It is the CSS named color blueviolet.
Color values
| HEX | #8A2BE2 |
| RGB | rgb(138, 43, 226) |
| HSL | hsl(271, 76%, 53%) |
| CMYK | cmyk(39%, 81%, 0%, 11%) |
| Decimal | 9055202 |
| CSS | color: #8A2BE2; |
| Android | 0xFF8A2BE2 |
| Swift | UIColor(red: 0.541, green: 0.169, blue: 0.886, alpha: 1) |
Accessibility and contrast
| White text on #8A2BE2 | 5.96:1 — AA pass · AA large pass · AAA fail |
| Black text on #8A2BE2 | 3.52:1 — AA fail · AA large pass · AAA fail |
| Recommended text color | white |
WCAG 2.1 asks for at least 4.5:1 for body text and 3:1 for large text (18 pt, or 14 pt bold).
Tints and shades of #8A2BE2
Each swatch keeps the hue and saturation of #8A2BE2 and varies only lightness — the quickest way to build a usable scale from a single brand color.
Colors that go with #8A2BE2
Harmonies generated by rotating the hue on the color wheel while holding saturation and lightness constant.
Using #8A2BE2 in code
/* CSS */
.element { color: #8A2BE2; background-color: #8A2BE2; }
.element { color: rgb(138 43 226); }
.element { color: hsl(271 76% 53%); }
/* Tailwind arbitrary value */
<div class="bg-[#8A2BE2] text-white">
/* SCSS variable */
$brand: #8A2BE2;
Frequently asked questions
What color is #8A2BE2?
#8A2BE2 is a medium, vivid violet, which CSS calls blueviolet. Its hue sits at 271° on the color wheel, with 76% saturation and 53% lightness.
What is #8A2BE2 in RGB?
#8A2BE2 converts to rgb(138, 43, 226) — 138 red, 43 green and 226 blue.
What is #8A2BE2 in CMYK?
Approximately cmyk(39%, 81%, 0%, 11%). Print output depends on the ICC profile of the press and paper, so treat this as a starting point rather than an exact match.
Should text on #8A2BE2 be white or black?
White gives the better contrast ratio (5.96:1 versus 3.52:1).
What is the complementary color of #8A2BE2?
#84E22C — the hue directly opposite #8A2BE2 on the color wheel.