Increasing the Loading Speed of a Joomla Website
One of the main concerns about open-source Content Management Systems (CMSs) is the loading speed of web sites that run on these CMSs. Most open-source CMSs are designed in a very modular way with a lot of redundancies, which means they have more files to load, making your website heavier and thus slower to load. This factor, however, should not sway you away from using open-source CMSs, especially a CMS like Joomla, because with just a few simple steps, your web designer can optimize the performance of your web site by a large margin.
The slow loading speed issue does not apply to Joomla alone. In fact, it applies to all open-source CMSs. And with the recent version of Drupal 7, which is said to be much slower than the previous one, Joomla websites have a much easier time to complete with Drupal sites.
- Find out what files are not being used and remove all unnecessary files. Get FIREBUG addon for Firefox and click the NET tab from it. Enable all the scripts and console and images detection there. Refresh your site. While the site is loading, keep a close watch to FIREBUG NET tab and see what is loading and what is where. It will clearly show you which part takes most loading time and all the unnecessary files or scripts, all while the site opens. Take a good report from it and optimize based on this information.
Get YSLOW extension from Yahoo! and install that with Firebug. It gives advanced Performance Detection options. One of the main reasons for Joomla sites loading slowly are many unnecessary JS files and images. You need to remove all files which you know are not being used by the site. - Install performance optimization plugins. If you are using pre-made templates designed by reputable web design houses, you are ahead of the game already. Joomlart and Rockettheme both have speed optimization components out-of-the-box. All you need to do is enable them. If these components don't work for some reason, there is a number of plugin you can try: we used JotCache plugin and we loved it. All such plugins will try to optimize CSS, Java script and HTML sizes.
- Enable Joomla system caching plugin. This alone can give a huge boost in speed. It pre-generates static portions of a Joomla web site to avoid excessive real-time page generation.
- Activate GZip compression and caching options in Global Configuration. Here is an article that explains well how compression works.
- Optimize MySQL performance. Here is a short and sweet article that explains how to optimize MySQL in a couple of simple steps, which can be done from your hosting control panel.
- Optimize Joomla main-menu speed. We only tested this on Joomla 1.5. This will speed up the slowness caused by Joomla's mainmenu module, which can take several seconds to generate a web site menu, should it get too large or too deep. Additionally,
- Optimize code. Writing CSS, Javascript and image codes following certain standards can help decrease the size of their respective files. Effect depends on how much content your are adding into the site. CSS files can be aggregated and compressed into a single file, while JavaScript files are only aggregated but not compressed.These optimizations may reduce server load, bandwidth requirements, and page loading times.
- Optimize images used for the site by tweaking quality and compression methods. This is especially important if you are producing your own web banners. If you are using stock images or reusing images that come with the templates, decide on your own if you can trust the designers to do their job.
- Here is a couple of places where you can run image compression: There are some reports on forums that .jpg extensions make the site load faster than .png extensions.
- Optimize server connection. In almost all cases the site's speed can be increased dramatically by a better server/connection. Bear in mind that visitor location and ISP heavily influence the final loading speed of a webpage. Check out this server optimization guide (note, though, that some steps included in this guide are out of date, so read carefully).
- Decrease the number of extensions used. Try to run your site minimal number of extensions. The more extensions, the longer it will take for your site to load. Do as much work from the core as possible.
- Get your social media buttons (likes and pluses and shared) to load after the page they are displayed on has already loaded. Those buttons slow down the loading speed significantly. To enable this, you need to do some custom coding or find an existing plugin (we use custom coding).
- Use free services like GTMetrix to analyze your site. GTmetrix generates a free audit report on your site's speed performance and provides recommendations on the most important issues.
Another main reason for the slow loading speed is SEF (search engine friendly) components and the SEF URLs . If you switch off your SEF, then you will see, just 50-60 queries being run from the DEBUG mode, but with SEF enabled, you will have around 300-1000 queries (depends on the site) run at the same time, making your site slower. However, disabling this component will make your URLs not user friendly, containing all the gobble-de-gook characters and question marks, and you probably don't want it. So, our recommendation is to leave this one on.
Summary
By enabling caching, optimizing MySQL, installing compression plugins (such as JotCache) and making sure your extensions, code, CSS and images are done in the most economical way - all this taken together will speed up your Joomla web site by 100%-300%.