Skip to content
Siolon
Siolon
  • Home
  • About
  • Archives
  • Testimonials
  • Contact
Siolon

CSS Browser Reset

Chris Poteet, March 24, 2008April 6, 2009

A trendy topic amongst CSS’ers is the CSS reset. The idea is that you intercept the default browser stylesheet (that is used first in the cascade), reset, and then apply generic styles including margin/padding. I read many articles by many gurus, but I eventually came out with what I have below.

For differing implementations check out this great “killer collection” of resets, and note that this won’t work in IE6 due to the universal selector but I’m ok with that.

/*

Reset Default Browser Styles
- Place first in the listing of external style sheets for cascading.
- Be sure to explicitly set margin/padding styles.
- Styles are not reset that have to do with display (block, inline) are not reset.

By: Chris Poteet & various influences

*/

* {
vertical-align: baseline;
font-family: inherit;
font-style: inherit;
font-size: 100%;
border: none;
padding: 0;
margin: 0;
}
body {
padding: 5px;
}
h1, h2, h3, h4, h5, h6, p, pre, blockquote, form, ul, ol, dl {
margin: 20px 0;
}
li, dd, blockquote {
margin-left: 40px;
}
dt {
font-weight: bold;
}
table {
border-collapse: collapse;
border-spacing: 0;
}

Related Posts

Design User Interface CSSresetTypographyuiWeb Design

Post navigation

Previous post
Next post

Comments (31)

  1. Jeff Starr says:
    June 11, 2008 at 6:48 pm

    Thanks for the link, Chris! I finally got around to updating my collection with your CSS reset. Great work!

    Reply
  2. Chris Poteet says:
    June 11, 2008 at 7:07 pm

    Thanks Jeff!

    Reply
  3. Pingback: KRUZ-GRAPHIX » ブラウザの差異をなんとかしたいのです。
  4. Pingback: 5 Удобных CSS Reset Техник | Strelban's Blog.
  5. Pingback: Técnicas para resetear CSS | CSSBlog ES
  6. Pingback: How to reset elements in CSS « CssFinest
  7. Pingback: Bermain CSS #1 | eattutsmagazine
  8. Pingback: » ???????CSS Reset - WEB????- ?????????????
  9. Pingback: CMI Web Studio Blog » Reseting CSS Styles
  10. Pingback: CSS Reset – Anfängerkurs « stella.projects
  11. Pingback: iConnect » Técnicas para reset CSS
  12. Pingback: CSS Reset: Ways and Advantages | Inspiring Pixel
  13. Pingback: CSS Reset | Sarasota Web Design, 3d Animation, Video, Audio
  14. Pingback: An (Almost) Complete List of Global CSS Reset Styles | kmsm
  15. Pingback: 11 useful CSS snippets to save your time – Red Team Design
  16. Pingback: ????CSS « DS LAB.
  17. Pingback: CSS Reset – O que é e como usar? » Info Adris
  18. Pingback: ????? ??????. CSS reset | DenWeb
  19. Pingback: Técnicas para resetear CSS
  20. Pingback: renan martins pimentel
  21. Pingback: 10 técnicas para resetear CSS - 1 + 1 | Blog
  22. Pingback: Sacima?????? » Blog Archive » Useful CSS Snippets for Your Coding Arsenal
  23. Pingback: Useful CSS Snippets for Your Coding Arsenal |
  24. Pingback: Algumas técnicas para resetar o CSS | renan martins pimentel
  25. Pingback: Useful CSS Snippets for Your Coding Arsenal « Web Study Online
  26. Pingback: CSS Snippets for Your Coding | prosoxi.com
  27. Pingback: code snippet | Free Web Designer Tool
  28. Pingback: Useful CSS Snippets for Your Coding Arsenal
  29. Pingback: Resetear CSS – Para qué sirve y cómo lo utilizo « Front End Ninja
  30. Pingback: Técnicas de Reset CSS | Giluan Souza
  31. Pingback: Useful CSS Snippets for Your Coding Arsenal

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Search

        ©2025 Siolon | WordPress Theme by SuperbThemes