I’ve been messing around with different caching options over the last few months within WordPress and watched a few tutorials.. I’ve also read a lot of articles on the best approach to take to speed up WordPress sites. So, I thought I’d share with you my definitive list of caching options and plugins that I use. I’ve tried lots of combinations and options, but has found the list below is best for my site and the evidence is shown on google page speed.
First things first, make sure your host can offer some sort of PHP caching options like OpCache and/or Redis. If they dont offer any of these options, then I’d suggest you find another host that does as this will dramatically increase the speed of your site. I currently run my website on my own host (raspberry pi 3) and have found I can get pretty decent results from Google page speed.
Below is a guide on how to install Redis on your host or your linux (ubuntu, debian) box.
- install Redis server – “apt-get install redis-server”
- edit configuration file – “nano /etc/redis/redis.conf”
Change the following settings and SAVE the file-
- install Redis php extension – “apt-get install php-redis”
- check installed “php -m | grep redis”
- Install WordPress “Redis Object Cache” plugin
- Enable the object cache by going to “Settings” then “Redis“, then click “Enable Object Cache” button
- You can now check that the Redis server is caching WordPress objects by typing ‘redis-cli‘, then typing keys “*” from the Linux command line.
There is 2 plugins that I swear by when setting up wordpress caching.
firstly is a free plugin called “WP Fastest Cache“. This plugin is lightweight and few simple to use. There’s not loads of screens to change numerous options on.. it’s simple and elegant.
Secondly, a found a paid plugin called “Asset Cleanup Pro“. In my opinion, this is the best add on caching plugin to give you that bit extra speed. It allows you to disable or remove js/css scripts from certain pages when its not required.. This is also the plugin that can help with the deferring of scripts. I’ve tried lots of free plugins and can never get them to work correctly and find them too complicated. This on the other hand was simple and easy to use..