If you want your WordPress blog to load up quickly, then you want to use a cache plugin for it. There are two popular WordPress caching plugins: WP Super Cache and W3 Total Cache. Both of these work great but today we are going to talk about configuring WP Super Cache settings.
Web page load speed is an important factor for search engine optimization. Using WP Super Cache, your goal is to increase your web page load speed by serving cached html files stored in your server instead of dynamically generated server resource hungry pages. You’d also want to update your cache as your contents update.
Install this plugin and activate it. Here’s a generalized tutorial on how you’d do for WordPress add-ons.
After installation, follow these guidelines for configuring WP Super Cache:
Access it from Settings > WP Super Cache. You will find settings organized into tabs: Easy, Advanced, CDN, Contents, Preload, Plugins and Debug.
Quickest/Basic Way for Enabling Caching
On the Easy tab, just select “Caching On” radio button as shown in the thumbnail above and you are done.
Configuring Advanced Caching Features
Visit the “Advanced” tab of WP Super Cache Settings.
Make sure the following check boxes and radio buttons are turned on:
- Caching✓ Cache hits to this website for quick access.
✓ Use mod_rewrite to serve cache files.
- Miscellaneous✓ Compress pages so they’re served more quickly to visitors.
✓ Don’t cache pages for known users.
✓ Cache rebuild. Serve a supercache file to anonymous users while a new file is being generated.
- Advanced✓ Mobile device support.
✓ Extra homepage checks.
Hit the “Update Status” button to save your configuration.
After you enable or change mod_rewrite rules, you will have to update your .htaccess file located in your root directory. Hit the “Update Mod_Rewrite Rules” button to do this. The confirmation should display something like: “Mod Rewrite rules updated!” with all the rewrite conditions code displayed below it.
Expiry Time & Garbage Collection
Cache Timeout: 3600 seconds
Clock: 00:00 HH:MM
You can also try putting higher values like 86400 seconds if you want the cache to be declared fresh for an entire day (24 hour period) before it is marked stale. I tried using 86400 in my other website which is not frequently updated.
Also configure garbage collection time and interval. Only at this time, those stale files are refreshed. You can change this value to Timer: 600 seconds if you want your cache to be scanned every 10 minutes for stale files. This might cost you on your server resources. Shared hosting users will be better off with the settings shown in the screenshot with weekly refresh schedules.
Accepted Filenames & Rejected URIs
Leave it as it is (all unchecked) because you want to cache all the pages according to the settings that you have set above. Some people prefer not to have their home pages cached can check the Home (is_home) option. Remember a new cache of the homepage is generated every time you publish a new post.
Enable, if you do not want new comments to stop refreshing your cache. This option is generally meant for those websites which are taking a traffic hit with continuous comments and cache refresh due to those comments. This will save your server from refreshing posts hundreds or thousands of times, depending upon the comments you receive. Works good to save your server resources.
Leave other options as it is in the advanced settings.
This tab is meant for people who need to configure their content delivery network to work with WordPress. There is a tutorial on how you can use Dropbox as a CDN for WordPress using WP Super Cache plugin.
This tab is for viewing your cache stats. Not much configuration here. You can use this page to manually delete expired files or to clear the cache. You will have to regenerate cache stats to update this page.
This tab is to configure caching of all posts and pages beforehand. Turn on preload mode and if you have thousands of posts specify to preload a specific number of new posts from the dropdown. You will have to press “Preload Cache Now” button to start the process of caching all the pages immediately.
This tab is useful for adding features to WP Super Cache. If you use Jetpack Mobile Theme or WPTouch enable the individual plugin built for them. Then make sure you’ve checked “Mobile device support” in the “Advanced” tab of WP Super Cache. This will extend the support of this plugin to mobile version of your website. Not necessary if you use responsive templates.
You might be interested in: Five Ways to Make Your WordPress Site Mobile Friendly
Testing Your Settings
After all the configurations have been made, visit the “Easy” tab once again and use the “Cache Tester”. Click the “Test Cache” button and it will perform a simple test to see whether caching has been turned on. If the timestamps on both pages match, then you can be sure that your website is serving cached pages.
You can also view the source of your WordPress website from your browser. At the end, after </html> it should say:
<!-- Dynamic page generated in 0.863 seconds. --> <!-- Cached page generated by WP-Super-Cache on 2014-05-25 22:46:36 --> <!-- Compression = gzip -->