How To Setup WordPress CDN – Max CDN & Cloudflare CDN Step by Step Guide


For every one second delay in your page loading time your conversion fall up to 20%especially on the mobile. Setting up a CDN to the website is one of the best ways to boost your page load time.


Yes, who likes to see the loaaaading…. pages. The conversion fact which I told above is told by Google in the Google Next 2017 event. It’s an interesting fact I came to know while making the How to make Google Ads post.

There is a lot of ways to optimize the speed of your website, the most important one in that is CDN. Let’s see how to setup CDN in WordPress website today with MaxCDN and CloudFlare CDN.

[the_ad id=’6609′]

Difference Between MaxCDN and CloudFlare CDN

Both the CDNs improves your site speed, but they differ in the way they approach. Maxcdn does not require you to change the DNS to its server, it serves contents through your DNS itself by pull zone method.

That is, it pulls the static assets from your website cache it and serve it through their CDN networks. It has its own limits, it cannot access password protected directories and it can only serve small size static assets only.

Whereas CloudFlare requires you to change the DNS to its server and serve the contents through its own server. The benefit of this is, you get more security and reduce the spammy content. Due to its high-security nature, you need to disable it for email services and FTP.

In short, Maxcdn is easy to setup and is ideal for normal websites. If you need more security and have enough time or experience to play with the DNS and server-side processes use CloudFlare. Saying that, let’s see how to setup WordPress CDN

[experts_box experts_title=”Easy One Click Solution:”]Add the best CDN to your WordPress website in a click. Get the CDN Install & Configure support services.[/experts_box]

[the_ad id=’6614′]

Setting up Maxcdn in WordPress Site

As MaxCDN works on your site’s static content and cache data, this can be easily done through W3 Total Cache. Follow the steps to setup WordPress CDN through the cache plugin.

  1. Setup Pull Zone from MaxCDN
  2. Adding CNAME record for your domain
  3. Configuring the MaxCDN to the WP3 Total Cache

Setup Pull Zone From MaxCDN

Create your MaxCDN account and login to your dashboard. Click the Zones menu, in that select the Pull Zones tab.


Fill in the required details mentioned in the window.

“Name” it is the name of your site, mostly give your site name (without .com) to maintain your website easily.

“Origin Server URL:” enter your site’s present URL

Your Pull Zone will be created with a unique Zone ID and your CDN URL will be shown. Create a custom CDN name, that you can easily remember and identify like Do not close the window we still need the MaxCDN dashboard.

Adding CNAME Record For Your Domain

After this, we have to configure the CNAME to the hosting. Get into your hosting cPanel, in that select the DNS Zone editor.


Under the DNS record fill in the details, set type as CNAME. In the Points To sectioncopy the CNAME to link in your MAXCDN Pull Zone settings and paste it in your hosting cPanel. Scroll down to the CNAME section in your cPanel to check whether the new CNAME has been added.

[the_ad id=’6616′]

Configuring the MaxCDN to the WP3 Total Cache

Install the WP3 Total cache in your WordPress website and activate. You will see a new “Performance” option. Go to Performance > General Settings

Under the Page Cache click “enable” option and check whether the Page cache method in Disk: Enhanced and save the settings.

Next, enable the Minify option and set the Minify mode to Manual. Enable browser cache also. Under the Database Cache make sure it is not selected, it should be OFFby default.

Under the CDN option enable the CDN and set the CDN type to the MaxCDN. On the next screen click on the Authorize button. From the MaxCDN website generate an authorization key. Copy the key and paste it in the W3 Total Cache.

In the “Replace site’s hostname with” give the custom CDN name that you gave in the MaxCDN account. Click the Test MaxCDN to check whether it’s been integrated properly. If the test result shows PASS, then click the Save all settings button. That’s all now MaxCDN is setup in your WordPress website.

[recommened_reading id=”2548″ title=”Recommended Reading:”]

Setting up Cloudflare CDN in WordPress

CloudFlare can be easily installed through two methods. One is through the hosting cPanel and other is through setup CDN in WordPress through the plugin.

Beware: Before continuing to Cloudflare installation you have to be aware of certain facts, which I had mentioned after the Cloudflare setup instructions, take a look.

By Hosting cPanel

Here we are going to explain with the SiteGround cPanel, more or less it will be same in all other hostings. First log into your hosting cPanel to set up CDN in WordPress website.

Under domains section you will see the CloudFlare icon, you will be briefed about the CloudFlare and its plans. Mostly we choose the free plan if you need an extra bit of security and advanced features you can choose the required plan you want.


[pro_tip title=”Pro Tip:”]Please note that CloudFlare network is only used when the website is accessed with WWW. To use the CDN service fully and to always have your website served from the closest location to your visitors you need to reconfigure your website to redirect to WWW URLs. [/pro_tip]

Click yes to automatically redirect your website to the WWW domain version of your website. Auto redirect supports for the free plan only, if you are using the PLUS plan you have to manually configure your redirect.


But hey it is WordPress, you can setup redirection easily from the admin dashboard itself. Login to your WordPress admin panel, go to settings > general. Under the WordPress address (URL) and the Site address (URL) fields enter the domain with WWW i.e. for example like this “”

You can also do this with the .htaccess file also. Log into your cPanel, go to your WordPress installed directory, find the .htaccess file and paste the following code.

[code language=”php”]
RewriteEngine On
RewriteCond %{HTTP_HOST} ^ [NC]
RewriteRule ^(.*)$$1 [L,R=301]

In the place your required domain name, now your old domain will be redirected to the new www version of your domain name.

[the_ad id=’6609′]

Setting Cloudflare CDN in WordPress Using Plugin

CloudFlare can be setup using the CloudFlare WordPress plugin also. This method is more or less like integrating your CloudFlare account to the plugin.

For this method also you have to create a CloudFlare account first with all the website details as mentioned in the hosting cPanel method.

After installing the plugin follow the steps mentioned below.

1. Go to the CloudFlare plugin setting pages on your WordPress admin panel and login to your CloudFlare account

2. In the next step, you will be asked to enter your email and API key (this can be found in your CloudFlare account’s Global API settings)


3. You will be next taken to the CloudFlare settings home page. To make the normal recommended settings to be set, click “Apply” button.


To know more about CloudFlare CDN settings details and their impacts, take a look at this Cloudflare CDN settings post by Siteground.

Facts To Be Aware Of CloudFlare CDN

CloudFlare CDN offers a lifetime free CDN to your website. As mentioned above you cannot use the SSL to your site provided by your hosting. For that you have to pay separately again. As mentioned in our Aug 2017 WordPress Roundup, the https is no more an option it is an important factor for Google.


If you already have a well Google-indexed website with nice SEO ranking before changing your domain to www version think twice. As mentioned above Cloudflare CDN transfers the content of your site through its own CDN for that you need to add WWW to your domain name.

If you already using the domain name in www format then you are well and good, you can proceed without any hesitations. If you are not using the form then it may result in some SEO ranking issues. I am not sure whether Google looks both in the same way, but I do notice some minor issues when I tried www for one of my websites.

The next major point is its security. The CloudFlare is the one for whom speed and security both matters. This security itself sometimes causes a bad experience among the visitors. Sometimes even the legitimate users are prohibited to see the websites. It’s a rare scenario mostly minor, but if you are really serious about your website this minor thing also counts.

[the_ad id=’6616′]

So What’s Your Choice

Now you know how to setup CDN in WordPress website. Being a WordPress maintenance and Support service provider we helped many WordPress websites. Some of the issues we mentioned are the one which we came across when we try to fix our customer’s websites.

Both has its own pros, based on your requirement choose the best one you need. If you need fast and secure website get the Cloudflare. To be more user-friendly easy to maintain even for beginners get the MaxCDN.

Leave a Reply

Your email address will not be published. Required fields are marked *