How to Setup the WP Super Cache Plugin and MaxCDN in WordPress

In a world where the average Internet speed is well over 2.8 Mbps, it is crucial for a site to run at its peak speed. A single second’s delay in a site’s loading time could lead to a 30% loss in business. Search engines like Google, love speedy sites. That’s because Google does not want to waste it’s searchers’ time, by presenting them with slow sites.

In fact, the faster your site loads, i.e., lower the page load time, higher it climbs up the Search Engine Results Page (SERP). Therefore it’s a well-established fact that you need a fast site.

If you’re using WordPress, you have made the best choice for the foundation. Its ability to adapt to any and every project requirement makes it a brilliant CMS platform.

A quick note to our new readers – if you’re fairly new to WordPress, we’ve made a short introduction to caching especially for you! It is our belief that a strong foundation of a phenomenon is required, before attempting to implement it. Have a quick read and let us know of any questions. As soon as you’re done, jump into the tutorial.

What is Caching?

Caching, in very simple terms is saving data in the client’s web browser, rather than transferring it from the server for every request. For example, consider a background image in your blog. You have multiple pages, but each of those pages have the same background image.

If you were to transfer a fresh copy of the background image (from the server), every time a new page loads, then it would consume a lot of bandwidth and increase the page load time. In essence, you would end up wasting time and resources.

What if you could save that background image in a temporary directory in the user’s device? Every time the image needed to be displayed, it could simply display it from the temporary storage or “cache”. The cache, known as browser cache is supported in all devices – be it a smartphone, tablet or laptop.

This idea of reusing data, is called caching. Of course, there are a load of other factors such as cache expiry, non-cacheable objects, etc. – but we just require a simple definition for the purpose of this tutorial.

Implement Caching using WP Super Cache

WP Super Cache has been developed by Automattic – the team being out beloved CMS. We first download and install WP Super Cache from the WordPress plugin repository.

How to Install WP Super Cache?

We prefer to accomplish this task directly from the WordPress dashboard as it’s much quicker.

Simply head to WP Dashboard > Plugins > Add New

Search for “WP Super Cache” in the search box

You’ll find that the first result is the plugin you’re looking for. Notice that the plugin author is Automattic. That’s your confirmation.

Select Install Now

Once the installation completes, click on Activate Plugin.

Activate and Configure WP Super Cache

Since WP Super Cache is developed by Automattic’s seasoned developers, we can be certain of one thing – simplicity.

Phase One:

The first time you activate the plugin, you’ll find a yellow notification bar on the top.

It should appear for the first time.

As of now WP Super Cache’s caching features aren’t activated.

Just click on Update Status to check if the yellow message bar disappears.

If the file and directory permissions of the WordPress directory are set to their default values, then you should not get any error.

In case you go get an error, contact your hosting provider and fix the error in order to proceed further.

Phase Two:

We will now activate WP Super Cache’s caching features. Simply click on Caching On (Recommended) and click on Update Status.

This will activate the default settings of the plugin.

It is recommended that most folks stick to the default settings as they are usually fine-tuned to work with most hosts, without causing any compatibility issues.

Once you enable caching you can now check if the plugin is actually working. Simply click on Test Cache and you’ll get a message that reads:

The timestamps on both pages match!

This means that caching is a 100% functional in your site.

This brings us at a break-point. For folks who are new to WordPress and WordPress caching, we would strongly recommend you to stop here and not edit the advanced settings on a live site.

If however, you’ve made a backup and would like to explore the additional and advanced settings – we welcome your curiosity!

Exploring the Advanced Settings in WP Super Cache

Now, we will take a look into some of the advanced features of the WP Super Cache Plugin.

The Advanced Tab

The Advanced tab houses a variety of caching options, a few of which we will explore here.

Under the Caching sub-part of the Advanced tab, we’ve selected the mod_rewrite technique to serve cached filed. mod_rewrite is a C header file which tells the server how to serve the cached files.

Next, we take a look at the Miscellaneous settings.

We activate the ones that are marked as (Recommended).

If you want the known users (folks having an account in your WordPress site) to be served with the cached files, then check the Make known users anonymous so they’re served supercached static files

Check the rest of the settings as shown in the screenshot,

Word of caution: Under the Advanced subsection of the Advanced tab, we really recommend against modifying any of the settings – unless you know exactly what you’re doing.

Since these settings are highly specific to the requirements of the website and vary with the environment conditions – for example, server configuration, site traffic and data content; we would not be modifying any of them.

In order to save the settings, click on the Update Status button. Next, you’ll find a big yellow box with all the new settings written on it. WP Super Cache will now ask you to save the settings in htaccess file. Simply click on the Update Mod_Rewrite Rules button to save the changes.

If all goes well, you should be seeing that green message box informing you that rewriting the rules to the .htaccess file was successful.

The Contents Tab

This tab gives you an overview of the cached data in your site. You can manually delete the cached files in this tab. This is especially useful for testing purposes. WP Super Cache stores the expired cache files in your blog. Remember cached files expire after ever 1800 sec or 30 minutes.

Finally you can also regenerate the cache statistics for the most up-to-date information of your cached files.

The Preload Tab

The Preload tab is like a manual switch for WP Super Cache. It enables you to cache each and every post and page in your site, right from day one. Although this process is resource intensive in the beginning, it would pay off in the long run as the search bots would get the cached version of the site – which would always be served faster than the dynamically generated version.

Caution: If you are on shared hosting, please make sure to keep at least 10 hours or 600 minutes as the cache preload interval. If you go any lower, you might be suspended for server resource abuse. Normally we would recommend you to manually preload the cache depending on the amount of new data that’s published in your site.

The CDN Tab – How to Link MaxCDN with WP Super Cache

WP Super Cache provides you with the easiest way to integrate a CDN in your site. As far as WP Super Cache is concerned, you need to configure your CDN provider and use a pull request to load the files from your server into the CDN’s infrastructure.

As with the previous tutorial, head over to your MaxCDN control panel and select the Zones 1tab. This will bring you to the Pull Zones Overview page. Select the Create Pull Zone button.

Under the Pull Zone Settings, enter the data accordingly, and make sure that the Origin Server URL contains the base URL, without the trailing slash. Even if WordPress is installed in http://www.mycompany.com/blog/ the base URL would be http://www.mycompany.com.

Click on Create to start creating the Pull Zone. You should get a similar message as the one shown above.

After about ten seconds, you should get a confirmation message indicating that the pull zone has been created.

Head over to MaxCDN Control Panel > Overview > Zone Configuration and find the new Pull Zone that you just created.

Copy the CDN URL and add an http:// to it.

Paste the full URL (without the trailing slash) in the Off-site URL field under the CDN

Next, scroll to the top and select Enable CDN Support.

Don’t change any other settings.

Simply click on Save Changes to activate the CDN.

The Benefits of a CDN

Using a CDN service to speed up your site yields positive results.

First off, the content gets delivered to your visitor in the fastest possible time.

This improves user experience.

Moreover, the load time decreases, which is a +1 in Google’s eyes.

You get a two fold benefit out of this deal and end up saving a lot of costly bandwidth from your hosting company.

Conclusion

We all love faster sites. In the days to come, the Internet’s going to get faster and better. It would be quintessential for every webmaster to strive for the site’s optimum speed. This makes caching your WordPress site as one of the most important tasks.

We’ve discussed one of the easiest ways to implement caching in your WordPress site! And we believe that you’ll be able to see a real difference with the new settings.

If you’re one of those folks who want their business to succeed and make it large in the Internet world, this article is for you.

Thanks for this! Very useful information 🙂
I had read in another site that the best setting for preload was 5000, so I have it like that. Should I change it to 0? This was before I added MaxCDN, I never changed that setting since.
I have small blog, I only have around 400 posts, and I only post 3 times a week.
Thanks!

Participate in this conversation via emailGet only replies to your comment, the best of the rest, as well as a daily recap of all comments on this post. No more than a few emails daily, which you can reply to/unsubscribe from directly from your inbox.

Full Disclosure This post may contain affiliate links, meaning that if you click on one of the links and purchase an item, we may receive a commission (at no additional cost to you). All opinions are our own and we do not accept payments for positive reviews.

Exclusive deals

WPX Hosting: 50% OFF

About WPKube

WPKube is an online WordPress resource which focuses on WordPress tutorials, How-to’s, guides, plugins, news, and more. We aim to provide the most comprehensive beginner’s guides to anything about WordPress — from installing plugins, themes, automated installs and setups, to creating and setting up pages for your website.

We have over 500+ tutorials, guides, product reviews, tips, and tricks about WordPress. Founded by Devesh Sharma, the main goal of this site is to provide useful information on anything and everything WordPress.