Continuing from part 1 (falling in love with your blog again), part 2 (widgetizing & thumbnailing) and part 3 (search engine optimization), in this part I share the steps I’ve taken to enhance the speed and performance of my blog.
Why is your blog speed important? Many reasons really:
- Affects your search engine optimization, yep bots do care about how fast your page loads
- Increases your site traffic indirectly; users are not patient, if your page takes some time to load they might close it down before it does
- Faster means less bandwidth means less costs
A good place to start is a quick health check, I use GTMETRIX which is money free, registration free, and awesome. It gives you basic ratings from Yslow (Yahoo) and page speed (Google) plus tips on what needs to be optimized.
Speed enhancement is mostly about caching really. I will divide this post in two parts, manual bits and plugin bits.
I am still not 100% done with my CSS changes so I chose not to cache them for the time being.
My server is Apache and hence I edited my .htaccess file with the following parameters (thanks to google of course):
Note that I have removed CSS (Stylesheet), HTML (web pages), plain TEXT and XML files from being cached.
You can read about ETags here, they have to do with setting up change frequency of content by adding requests to the HTTP headers of the site allowing your web pages, the server, and your browser to talk to each other and identify if a page needs to be refreshed from cache or not. I personally do not utilize this in my site so I opted to disabling ETags all together as recommended.
The .htaccess settings above take care of that, however before I applied those, I used to have this in my .htaccess:
After doing some research, I am convinced that the best tool to use (and easiest to setup and configure) is w3 total cache.
This tool is totally awesome! It supports page and database caching , it also supports minifying CSS and JS files, and it supports Content Delivery Networks whether external or self hosted.
I installed the plug-in following the instructions in the readme file. I then retained basic / recommended settings for the tool:
My Current page ranks at B on YSlow! (Yahoo) and B on Page Speed (Google) which is really awesome compared to D and D before undergoing this optimization practice. I still haven’t utilized CDN as well, once done I believe I will be hitting A’s.
This is the 4th and last part and where this experience sharing ends. If you have any questions, please post them.
Lets us know if you have used any tips from the 4 parts experience. Have you?