7 Free Tools to Minify your Scripts and CSS

I have been doing a lot of Client-Side development recently and I have found these 7 tools of great help to improve the performance of the website by ‘shrinking’ the size of JavaScript and CSS files, referenced in the site.

JSMin (JavaScript Minifier) - removes comments and unnecessary whitespace from JavaScript files

JSO (JavaScript Optimizer) - allows you to manage your JavaScript and CSS resources and to reduce the amount of data transfered between the server and the client.

Packer – An online JavaScript Compressor

JSCompress.com – Online tool that uses either JSMin or Packer to compress your files

CSS Compressor – Online tool that compresses your CSS file

DigitalOverload JavaScript Minifier – Online tool that minifies your JavaScript files and finally the one I use most frequently:

YUI Compressor – A JavaScript minifier designed to be 100% safe and yields a higher compression ratio than most other tools.






About The Author

Suprotim Agarwal
Suprotim Agarwal, Developer Technologies MVP (Microsoft Most Valuable Professional) is the founder and contributor for DevCurry, DotNetCurry and SQLServerCurry. He is the Chief Editor of a Developer Magazine called DNC Magazine. He has also authored two Books - 51 Recipes using jQuery with ASP.NET Controls. and The Absolutely Awesome jQuery CookBook.

Follow him on twitter @suprotimagarwal.

13 comments:

Celso Endo said...

Hi!
There is also ShrinkSafe from Dojo.
It can be used without dojo toolkit and it's based on Rhino (Javascript engine from Mozilla). I use Shrinksafe and never had a problem! Very good!
http://dojotoolkit.org/docs/shrinksafe

Zubin said...
This comment has been removed by the author.
Zubin said...

How about the google closure compiler, they even host your optimized JS:


http://closure-compiler.appspot.com/home

kevin said...

Another online css compressor
http://www.miniwebtool.com/css-compressor/

Unknown said...

I wrote a couple of articles a while ago about minifying css/javascript on the fly. They utilise a mod_perl handler which intercepts outgoing css/js and compresses them on the way out. Compressing CSS on the Fly and Compressing JavaScript on the Fly

Anonymous said...

Here is another tool. You add it to your asp.net web site and it then minifies and combines the CSS files (and the JS files too):

http://www.codeproject.com/KB/aspnet/CombineAndMinify.aspx

print said...

Thanks for sharing all these blogging tips! I'm sure that will help me to improve my blog. I became your rss subscriber.

Anonymous said...

There is one more tool for js compression http://www.webrankstats.com/tools/javascript-compressor/
and for css compression http://www.webrankstats.com/tools/css-compressor/

Andrew Lundgren said...

Another tool for CSS minification in ASP.NET - StyleManager. It combines the style sheets too, so less HTTP requests.

Diogo Melo said...

I know another tool. It not only allows to compress JS and CSS but you can also use it to host your script.

http://lightningpacker.net

It's ultra fast. It's hosted ad Amazon EC2, it transmit gzipped files, with headers setting the right parameters of cache and it uses Minify under the hoods.

John said...

Thanks for the great post. For minifying my JavaScript files, I prefer the online tool on http://www.blimptontech.com They use UglifyJS to get the compression done. Which gives you a little obfuscation as well. One cool other feature that I have started to use a bunch is the combining of JS files. You can easily upload a bunch of files, it adds them all to a single one, then minifies the JS.

DomFilk said...

i find a free online service to minify js and minify css, so it will reduce the size of web page.

Unknown said...

I would recommend minifybeautify.com, it does both (minify and beautify) in zero click for many scripts (JS, JSON, XML, CSS, HTML, PHP). Simple and fast.