---
# System prepended metadata

title: What is CSS selector?

---

# What is CSS selector?

A CSS selector is a string or pattern which is used to select the element which you want to perform style. It is a part of CSS ruleset.
1- Element Selector
2- Id Selector
3- Class Selector
4- Universal Selector
5- Group Selector

# Why do you need CSS preprocessors?

CSS preprocessors like Sass, Less and Stylus to do best practices like CSS compression and concatenating is an easier manner.