How to use JCH Optimizer to speed up your Joomla site


Speed matters these days, especially for mobile websites. Mobile devices are smaller and have less power and resources than a full computer. So what does this have to do with your site? If your site is heavy and bloated it won’t load quickly. This isn’t good for your clients who are looking to buy/gather information from your website.


How do I make my Joomla site faster?

JCH optimizer is a small system level plugin for Joomla that compresses parts of your website to lessen the load for your clients’ web browsers. How does this work? It compresses the output from Joomla so that there is less data/communication required between the server and the browser.

You can get this plugin at:
Note: version 1.7 seems to work just fine with version 2.5 of Joomla.

Enabling JCH Optimizer

Go to “Extensions” => “Plugin Manager”. Find “System – JCH_Optimize” within the listings of plugins.

Select “System – JCH_Optimize” and change “Status” to “Enabled”.

Using JCH Optimizer

Under “Basic Options” (located on the right hand side) there are many options for JCH Optimizer. We’ll be going over its HTML/CSS/Javascript functions below:

Combine CSS Files – If “Yes” is selected, this option combines external CSS files into one file.

Replace @import – If “Yes” is selected, all @import properties will be placed into the combined css file.

Combine JavaScript Files – If “Yes” is selected, this option combines external JavaScript files into one file.

GZip CSS and JavaScript file – If “Yes” is selected, combined CSS and JavaScript files will be compressed for faster downloads.

Minify CSS – If “Yes” is selected, all unnecessary spaces and comments within your CSS file will be deleted.

Minify JavScript – If “Yes” is selected, all unnecessary spaces and comments within your JavaScript file will be deleted.

Minify HTML – If “Yes” is selected, all unnecessary spaces and comments within your HTML file will be deleted.

Defer JavaScript – If “Yes” is selected, a “defer” atribute is added to the JavaScript tag. This can improve performance by giving the browser the option to delay executing the script until the body has loaded.

Position combined javascript – This option allows you to choose the placement of the combined Javascript.

Lifetime (days) – Sets the lifetime of the cached combined files.


Options We Recommend

Combine CSS Files : “Yes”

GZip CSS and JavaScript file : “Yes”

Minify CSS : “Yes”

Minify javscript : “Yes”

Minify HTML : “Yes”

Position combined javascript : “Last found Javascript tag”


Issues we found with JCH Optimizer

For version 2.0+ for Joomla 2.5, we found that there was a problem with loading both the compressed CSS and JavaScript files. This has to do with how the .htaccess file was reacting to our specific server. We kept on getting a 404 error since the mod_rewrite wasn’t working well. Turns out in the “cache” folder of the plugin, you need to uncomment and modify the “RewriteBase” for JCH Optimizer. Please note that this part of the tutorial is for developers only.

Below are the instructions on how you can fix this issue:

  1. Go to your Joomla Root path.
  2. Go to “plugins/system/jch_optimizer/cache”
  3. Edit “.htacess” file within that folder (not the root .htaccess file)
  4. Go to line 50 or so (should be something like “RewriteBase /plugins/system/JCH_Optimizer/”)
  5. Change this to: “RewriteBase /plugins/system/jch_optimizer/cache/” (without the parenthesis)
  6. Save

This may not fix your issue with JCH Optimizer. If you’re still having issues, you can change the load order of this plugin to be at the top of your system plugin load order.