Override the text selection (highlight) color with CSS

If you want to override the default text selection or highlight color you can. Simple apply the ::selection selector in your CSS and change the color, font, or whatever you want.

::selection {
    background: #ffb7b7; /* Safari */

::-moz-selection {
    background: #ffb7b7; /* Firefox */
Leave A Reply
All content licensed under the Creative Commons License