Toolman

blueviolet — #8A2BE2

#8A2BE2

rgb(138, 43, 226) · hsl(271, 76%, 53%) · CSS keyword blueviolet

Can you put text on it?

ContrastBody textLarge text
blueviolet on white5.96:1AAAA
blueviolet on black3.52:1AA

As a background, blueviolet takes white text: 5.96:1 against 3.52:1 the other way. A colour picker will give you the hex and stop there, which is why so many palettes look right and fail an accessibility audit.

Using it

color: blueviolet;
color: #8a2be2;
color: rgb(138 43 226);

All three are the same colour. The keyword is one of the 141 CSS named colours — a list settled in CSS 2.1 and added to exactly once since, when rebeccapurple was standardised in 2014.

Colours close to blueviolet

Frequently asked questions

What is the hex code for blueviolet?

The hex code for blueviolet is #8A2BE2 — RGB 138, 43, 226.

Can I use blueviolet for text?

Yes. blueviolet reaches 5.96:1 against white, past the 4.5:1 that WCAG AA asks for body text.

Should text on blueviolet be black or white?

White — 5.96:1 against 3.52:1 the other way.

Other named colours

#8A2BE2 in full — tints, shades and harmonies · All named colours · Colour reference