Difference between reset vs normalize CSS
Last Updated :
18 Jun, 2024
Ensuring a consistent user experience across different browsers can be a challenging task for web developers. Each browser has its built-in styles, which can vary depending on the operating system or the browser itself. This variation can lead to inconsistencies in how a webpage is displayed to users.
To address this issue, developers use two main techniques: CSS Reset and Normalize CSS. Both methods aim to override the browser's default styles to achieve uniformity, but they do so in different ways. This article will explore the differences between CSS Reset and Normalize CSS, and how they can be used to create a consistent look and feel for your website across all browsers.
CSS Reset
Reset CSS: As the name implies, this technique removes all of the browser's default styles, restoring all HTML components to a uniform starting point. It is a "slash and burn" method that gets rid of all default styles, allowing developers to start from scratch. Since default styles, such as font size or margin, are rarely utilized, this approach is effective for headers and other elements.
Since we rarely utilize the browser's default font size or margin, this strategy works well with the default style for headers.
Reset typically functions by stripping the element down to default by using a universal selector to set all HTML tags to have the same font size, alignments, and no padding, margin, or border.
*{
border :0px;
margin :0px;
font-size:100%;
font : inherit:
}
Example: This illustration will demonstrate the reset CSS approach.
HTML
<!DOCTYPE html>
<html lang="en">
<head>
<title>
Resetting CSS | GeeksForGeeks
</title>
<!-- Import the CSS Reset -->
<link rel="stylesheet" href=
"http://meyerweb.com/eric/tools/css/reset/reset.css">
</head>
<body>
<!-- HTML Content -->
<h1>GeeksForGeeks</h1>
<h2>Difference between reset vs normalize CSS?</h2>
<h3>We Are Performing Reset CSS</h3>
</body>
</html>
Output:
RESET CSSExplanation: In the above example, we imported the reset CSS which removed the browser's default styles. we can differentiate between the browser's default CSS and CSS after we imported the reset CSS.
Default  CSS vs Reset CSSNormalize CSS
Normalize CSS: This technique aims to make browser styling consistent across all browsers without completely removing default styles. Normalize CSS provides cross-browser consistency while adhering to modern CSS standards. Including Normalize CSS at the beginning of your CSS file ensures that all browsers start with the same rules.
Example 2: This illustration will demonstrate the normalized CSS approach.
HTML
<!DOCTYPE html>
<html lang="en">
<head>
<title>
Normalizing CSS | GeeksForGeeks
</title>
<!-- Import Normalize.css -->
<link rel="stylesheet" href=
"https://necolas.github.io/normalize.css/7.0.0/normalize.css">
</head>
<body>
<!-- HTML Content -->
<h1>GeeksForGeeks</h1>
<h2>Difference between reset vs normalize CSS?</h2>
<h3>We Are Performing Normalize CSS</h3>
</body>
</html>
Output:
Normalize CSSExplanation: In the above example, we imported a Normalize CSS which set a standard value for every element which is consistent in all browsers.
we can differentiate between the browser's default CSS and CSS after we imported the normalize CSS.

Difference Between Rest and Normalize in CSS:
Reset | Normalize |
resets all of the user's agent-bundled styles for the browser. | ensures that the HTML elements' user-agent-provided default styling is consistent across browsers. |
Resetting makes a lot of pointless overrides in the styling and has a long chain of selectors. | Since it makes use of the User Agent's styles, there aren't many long chains of CSS Selectors to be noticed while normalizing. |
As it is practically impossible to find bugs, debugging is challenging. | It's simple to debug while normalizing |
Reset is Not Modular (no section breaking in styles) | Reset Isn't Modular (no section breaking in styles) |
Resets are intended to remove all default browser styles. | The goal of normalizing CSS is to apply built-in browser styling across all browsers uniformly. |
In conclusion, both CSS Reset and Normalize CSS are essential tools for web developers seeking to create a consistent user experience across different browsers. While CSS Reset removes all default browser styles to provide a blank canvas, Normalize CSS takes a more balanced approach by maintaining useful default styles and ensuring consistency across browsers. Understanding the differences between these two techniques allows developers to choose the appropriate method based on their specific needs. By implementing either CSS Reset or Normalize CSS, you can ensure that all users, regardless of their browser or operating system, will have a uniform and enjoyable experience on your website.
Similar Reads
Non-linear Components
In electrical circuits, Non-linear Components are electronic devices that need an external power source to operate actively. Non-Linear Components are those that are changed with respect to the voltage and current. Elements that do not follow ohm's law are called Non-linear Components. Non-linear Co
11 min read
JavaScript Tutorial
JavaScript is a programming language used to create dynamic content for websites. It is a lightweight, cross-platform, and single-threaded programming language. JavaScript is an interpreted language that executes code line by line, providing more flexibility.JavaScript on Client Side : On client sid
11 min read
Web Development
Web development is the process of creating, building, and maintaining websites and web applications. It involves everything from web design to programming and database management. Web development is generally divided into three core areas: Frontend Development, Backend Development, and Full Stack De
5 min read
Class Diagram | Unified Modeling Language (UML)
A UML class diagram is a visual tool that represents the structure of a system by showing its classes, attributes, methods, and the relationships between them. It helps everyone involved in a projectâlike developers and designersâunderstand how the system is organized and how its components interact
12 min read
Spring Boot Tutorial
Spring Boot is a Java framework that makes it easier to create and run Java applications. It simplifies the configuration and setup process, allowing developers to focus more on writing code for their applications. This Spring Boot Tutorial is a comprehensive guide that covers both basic and advance
10 min read
React Interview Questions and Answers
React is an efficient, flexible, and open-source JavaScript library that allows developers to create simple, fast, and scalable web applications. Jordan Walke, a software engineer who was working for Facebook, created React. Developers with a JavaScript background can easily develop web applications
15+ min read
HTML Tutorial
HTML stands for HyperText Markup Language. It is the standard language used to create and structure content on the web. It tells the web browser how to display text, links, images, and other forms of multimedia on a webpage. HTML sets up the basic structure of a website, and then CSS and JavaScript
10 min read
Backpropagation in Neural Network
Backpropagation is also known as "Backward Propagation of Errors" and it is a method used to train neural network . Its goal is to reduce the difference between the modelâs predicted output and the actual output by adjusting the weights and biases in the network. In this article we will explore what
10 min read
JavaScript Interview Questions and Answers
JavaScript (JS) is the most popular lightweight, scripting, and interpreted programming language. JavaScript is well-known as a scripting language for web pages, mobile apps, web servers, and many other platforms. Both front-end and back-end developers need to have a strong command of JavaScript, as
15+ min read
AVL Tree Data Structure
An AVL tree defined as a self-balancing Binary Search Tree (BST) where the difference between heights of left and right subtrees for any node cannot be more than one. The absolute difference between the heights of the left subtree and the right subtree for any node is known as the balance factor of
4 min read