---
title: "Discussion on \"[CSS] 6 tricks to make your CSS file smaller\" | Hashnode"
description: "Discussion on \"[CSS] 6 tricks to make your CSS file smaller\". ...without making it look weird or/and hard to read.\n1. If it's 0, drop the units\nEasy. If you're setting a margin, padding, box-shadow or anything like that, you can just put 0 instead 0px. 0 in CSS is always a zero.\nThe difference is usually 2 char..."
url: "https://hashnode.com/posts/css-6-tricks-to-make-your-css-file-smaller/6144e3ebe1f56817e36049c0"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [\[CSS\] 6 tricks to make your CSS file smaller](https://blog.css-princess.com/css-6-tricks-to-make-your-css-file-smaller?utm_source=hashnode&utm_medium=feed)

...without making it look weird or/and hard to read. 1. If it's 0, drop the units Easy. If you're setting a margin, padding, box-shadow or anything like that, you can just put 0 instead 0px. 0 in CSS is always a zero. The difference is usually 2 char...

Sep 17, 2021 · 4 min read · blog.css-princess.com  
Read the article

-   [#css3](https://hashnode.com/tag/css3)
-   [#css](https://hashnode.com/tag/css)
-   [#optimization](https://hashnode.com/tag/optimization)
-   [#refactoring](https://hashnode.com/tag/refactoring)
-   [#web-development](https://hashnode.com/tag/web-development)

## Written by

[Angie Borucka](https://hashnode.com/@css-princess)

@css-princess · Cork, Ireland

  
[View profile](https://hashnode.com/@css-princess)

Designer who can code.

Self-thought webdeveloper, currently working as lead designer in eCommerce.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
