Tweak ScreenshotFor people who have no idea what I’m talking about, CSS Tweak is a web based CSS optimization tool. It will take any CSS file and optimize the syntax, grouping your style declarations into shorthand where possible. It can also remove comments, and strip whitespace for maximum compression.

There are other tools out there that have more compression options, but I made CSS Tweak to be simple, fast and easy to use. This meant only including the features that I felt were the most useful. By concentrating on things like making the interface simple and straight-forward, the tool would be far more beneficial for the majority of users that wouldn’t want more advanced compression options.

One major difference from other tools however, is that you can stop it from altering your syntactical layout. Instead it will go through and stick with the code layout structure you have defined, and clean up any areas that are incorrectly formatted. Some other tools tend to reformat your CSS, and move things around.

I’m very flattered by people’s comments, it seems that people enjoy the simplicity and speed the most. Jeffrey Zeldman added the tool to his bookmarks over on Ma.gnolia which has flat out bowled me over! He mentioned that the tool could use a brief help page, which I’ve now added. Thanks Jeffrey.

I’ll be making a few updates to the tweaker over the next little while, I need to fix the pasting option I’ve fixed the pasting option, so you can now quickly paste your CSS into the tweaker.

Also, I need to clarify something – the tool doesn’t check the validity of your CSS. All it does is check that the file you are trying to tweak is actually CSS at all. I guess my error message is a little confusing. I did this to stop people uploading and trying to tweak JPEG’s or PDF’s for example. If you want to validate your CSS, use the W3C’s tool.

CSS Tweak is free and you can find it at:

Update: I have a forum set up where you can submit bug reports, or suggest enhancements for the tool. This way I can keep track of fixes to make for the next version.