My need for speed: 14 ways to speed up Joomla
As mentioned earlier, this site was meant to be and is a testing ground for me to test out various methods and experiment generally with different aspects of everything.
One
this I was and am adamant about is the speed of the site and so I
started to look for every trick in the book and tried to implement it.
From the joomla forums I found WSO
and gave my site a quick look. My results showed about 79 Http requests
and a loading time of 16.94seconds on a T1 connection! So I knew I had
work to do.
The following is what I did to speed up my site.
First the easily done methods.
1) Turn off Components, Modules and Mambots you don’t use;
This point I cannot stress enough, though it may just save you a few split seconds, it is a good practice to do.
2) Turn on caching in joomla;
If you go to Site>global configuration you will find an option to enable ‘caching’
3) Optimize and repair SQL Database;
As
you know (or don’t I didn’t when I started) everything on joomla is
done my queries to a central database and this may slow things down.
One
way to do the above is to go into Mysql and do it manually or set a
cronjob but in my need for an easier way I found the following
component SM2 db Health Check. This extension automatically repairs and optimises the database.
4) Use Page Cache;
this is an extra component by IRCmaxell which works well with the inbuilt joomla caching and can be found here.
5) Compress images;
According
to WSO the bulk of what was being loaded was images. So what I did next
then was grab all the images I was using and compress them using Irfanview and re-uploaded them; this shaved about 2 seconds of my time.
With
these done I saw a decrease in loading time but according to WSO things
were still not good so I tried some more tricks, these require you to
have mod_gzip enabled on you server and the ability to add/ edit your
.htaccess file, which should be in your ‘root’.
6) Enable Gzip;
In my travels I a came across this beautiful article on .htaccess tricks
and was determined to give some of them a go.In my case it was slightly
different to as described by perishable; all I did was add the
following ot my .htaccess file:
‘php_flag zlib.output_compression on’.
But wait you can compress some more! On the same site I discovered how to compress both CSS and JavaScript
This gave me the greatest speed boost from all the tweaks but remember this is a cost to some cpu power for compression.
This section requires tweaking your .css .js and .html files always save a copy before applying these tweaks.
7) Cut out images you don’t need;
Again
here I used WSO to identify all images and then once identified I went
through my .css files and deleted reference to this.
Clean up and optimise .css and .js files;
I firstly deleted all the ‘white space’ in the files. I then ran all the .css through an optimiser and all the javascripts through a separate optimiser this shaved about a second off my time.
9) Validate .css and html;
if there are errors the browser has to guess and what to do, and regardless there is a slight lag so use W3 to validate and fix both .css and .html files.
Now
my site has only 15 http request and loads in 3.30 seconds on a T1
connection. Yet my need is still great so what else can I do to improve?
10) Combining .css and .js;
This I am still working on but mpettitt gives a good quick idea how to do it here.
11) Upgrade to Joomla 1.5,
Ircmaxells latest test shows that there is a great improvement between 1.0 and 1.5 though the caching seems a bit odd overall it is better and faster.
12) SQL caching;
This
can be a great boost but requires a great deal of ram; in addition to
this ircmaxwell has also released a query cache component to his site
that you must check out if serious about this.
13) PHP accelerators;
Accelerators such as APC, Zend and xcache can provide a great boost also.
14) Use Lighttpd;
Ircmaxell’s other latest benchmarks test Shows that this is a lot more efficient by an average of 94% in dishing out you site.
That
is all I have done and what I plan to do if you have any other ideas
how to speed up a joomla site please let me know and I will add it here.
Popularity: 25% [?]
Related posts:
- Update – Links – Love – 5 Well I can’t say its great to be back from holiday…as who can truly say they WANT to leave Dubai. Though as always the blogosphere...
- 21 Comments
- Tags: Joomla, need for speed, speed up joomla, tweak joomla
Excellent information, Don! I will certainly be referring to this article during my next adventure into Joomla territory. Cheers!
Cheers Jeff; This article is actually dated. I took my joomla based site offline and moved my wordpress site to my main domain porting my old articles.
Though I have been tinkering with the new joomla 1.5 revision and have got a third part to this planned very soon.
That’s a great article, thank you for your great Job !!
cheers Homer glad it as of use
Great article! I used as much as I could and it really sped up my site that im going to be introducing soon. Bookmarked!
Glad it was of use
I’ll be coming back to read this article. My church’s website is on Joomla. It’s not really the best CMS platform (maintenance wise) but it does its job quite well
Indeed Joomla is VERY powerful once yo figure it out. and if done right can have brilliant speeds and content.
My joomla site is very slow
Hey man had a look at the site in your sig and it was not that slow
though I would suggest if you are suffering lag, optimise the image sizes and use caching.
Choice of template is half the game, in speeding up Joomla. Interesting to note that each image is equivalent
to 1 HTTP request. Less the image faster the joomla is. CSS code clean up, removal of extra stuff from CSS does help in decreasing HTTP requests.
There are two major variables to be considered when speeding up a joomla site, 1) size of files and 2) Http requests as you mentioned.
Combining CSS/JS files will HUGELY reduce requests and minifcation etc will reduce their size. In reards to images and speeding up joomla, the optimum method is to use css sprites, as this will mean one request instead of X and all it will take is a a line or two in your css files.
Side note I removed your link as it required a password to view; if it comes in the public domain then feel free to re-add it.
I certainly agree with your view of using CSS sprites, would be covering that in my article, thats strange that you found my article to be password protected. I have checked it again ….. http://www.joomspot.net/how-to-speed-up-optimize-joomlas-performance.html . will be covering combining / minification and css sprites in the article
hmm i’m still getting ‘To access the private area of this site, please log in. ‘
I heard everyone that Joomla is very powerful and fast. After trying some of your advices I came to conclusion that the most important factor when it comes to Joomla websites is the hosting. If you have a good hosting you’ll have a fast website. Easy as that. After trying some free domains moved myself to Wordpress . Not joomla but fast enough
Yep It Is true hosting is a big part; though since writing this post joomla has gone through many an update is very fast out of the box now.
Though the points mentioned in the article apply to wordpress as well as any other cms
I will practice your advise…on my website
[...] http://www.joomlaperformance.com/articles/performance/so_you_want_to_speed_up_joomla_3_14.html http://thenexus.tk/my-need-for-speed-14-ways-to-speed-up-joomlahtml/ http://extensions.joomla.org/extensions/administration/admin-add%252dons/6053/details [...]
Its great I’m still using J 1.0 for my site at http://dondandon.com and I hope your article here will fixed my slow loading problems.
Thanks!
Donna
I hope it will to
if you need a bit more help just hit me up on the contact form and i’ll help if I can.
Good information, I have done some of the items you list. The SM2 DB Health Check has been disabled because it is not compatable with joomla 1.5. Reading your article I realize how much I have to learn. I installed joomla with godaddy easy install app so I didn’t need to know css but I can see now that I need to learn css among some other things to run a good site.