WordPress Theme Minifier Plugin

June 17, 2010 Freebies, Resources

The latest and great WordPress plugin has been released thanks to Squidesma, and it is incredibly useful and very easy to use.  All you have to do is install it, and hit one button. Afterward, your selected theme has been optimized and minified.


What exactly does minified mean? The plugin goes through your entire theme and takes out unnecessary code and space, as well as optimizes it. Extra spacing between elements in your markup and CSS is great for development because it separates everything into sections, but you don’t need these extra spaces for production. Visitors on your website can’t tell if there is extra spacing in the markup or not when just viewing the website, so why have it there? That extra spacing bloats your file size which in turn causes longer load times and increased bandwidth usage.

Customizable and Reversible

Many may be worried that this plugin is going to break your theme. After all those hours and long nights of coding your perfect theme, you don’t want it to all be destroyed by a plugin. Worry not, Theme Minifier understands and has your back. There are various levels that you can minify your theme. The standard level will rip out all the white space in your markup. You can also choose which method to use when the plugin optimizes your JavaScript: JSMin or Packer. JSMin is the default because it is the most popular and most used, and Packer is often considered evil, however it results in smaller file size. You can then take it a step further and optimize your site’s CSS. For now, using this CSS optimization will break any CSS3 styles that you may be using such as any -moz or -webkit tags because it is not valid CSS.

After you choose your settings and the plugin runs, it will create a copy of your theme, and it will not automatically make your site use the new theme. If something in the theme would break and the plugin forced your site to use the new theme, all of your visitors would immediately see the broken theme. You will also have a backup which you can revert to at anytime in case there is a problem.

Having two copies of your theme, one original theme and one minified, has another advantage other than speed and optimization. You can deliver the minified theme to your visitors, and still have the markup laid out the way you like it. The original theme then becomes the development theme, which you can make all of your changes to with ease. When you are done making the changes, you can simply run the plugin again to minify the new changes.

Image Optimization

The Theme Minifier will also analyze and convert your images to whatever file type is the most efficient. Just like your theme, it will create a new version of every image it converts so your original images aren’t gone forever and damaged. Theme Minifier shows you a nice table showing what images it converted and gives you details like how much space you can save by using the new format. If you choose to use the new images, it is up to you to make the necessary changes in the markup.

Risk Free

Since the plugin gives you options and backs up your theme, why not try it out? It will only take a few seconds to install, and just as long to run. Make sure to visit the plugin’s page in the WordPress Plugin Directory or visit the author’s blog about the plugin. After your run the plugin, it will even give you a report on how much you saved, and where it was saved.

How Much Space Did You Save?

After you install and run the plugin, comment below and let us know how much space you saved!