Skip to main content

Code better with CSS Lint

CSS Lint

Whip your code into shape with CSS Lint

Performance gurus Nicole Sullivan and Nicholas Zakas have created a web-based tool that analyses your CSS code and detects problems and inefficiencies. Operating the tool is extremely simple: just drop your code into the box and click LINT! to get feedback on your work.

CSS Lint, with the tagline "Will hurt your feelings, and help you code better", is an open source project. It works by applying a set of rules such as "Don't use IDs in selectors" and "Don't use too many web fonts". Soon it will be possible to turn individual rules on and off using the web interface.

The project is available on GitHub, so you can contribute rules and extensions, and build a custom version for yourself by stripping out rules you don't want and adding ones of your own.

If you want to run it on your own system, there is a command line version for Node.js.

You can read more about it in these posts from Nicholas and Nicole