How to disable default text selection highlighting in CSS

In Websites, When we hover over any text element, it shows Text Selection ( I ) by default.

To disable this default text selection, Use this in CSS (style.css)

* {
user-select: none;

What use-select:none does

The user-select property specifies whether the text of an element can be selected.

In web browsers, if you double-click on some text it will be selected/highlighted. This property can be used to prevent this.

more info:



I'm a developer and my work is development

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store