Shopify: change CDNs to improve the speed of your store

Summary

After seeing how speed up the loading speed of your Shopify store en optimizing images, pre-loading pages et differing content, let's focus on the importance of CDN.

What is a CDN (Content Delivery Network)?

A CDN speeds up the delivery of your site's content by serving it from the servers closest to your visitors.

How to connect a CDN to your Shopify store?

CloudFlare

First of all it is necessary choose a CDN, there are dozens of them but in this article we will focus on the most popular and which has a free plan: CloudFlare. 

CloudFlare

Create an account on it and go to the next step.

Connect Cloudflare to your domain name

To benefit from Cloudflare services, you must replace the server you have base with the Cloudflare CDN.

To do this, start by adding your site to Cloudflare:

add your site to Cloudflare

add your site to Cloudflare bis

Select the free offer:

Free offer

Once this is done you will be asked to verify your DNS records. Unless you know what you are doing, skip this step.

We come to the most important step, modifying "your name servers":

Changing "your name servers

Set this page aside, we'll need it later.

Now that Cloudflare is ready to connect its CDN to our Shopify store, we're going to need to access thehost of our domain name. This step depends on where you purchased your domain name. For this guide, we'll take the most likely: from Shopify. If this is not the case, the approach will remain very similar whether it is at OVH, GoDaddy, Amen, Namecheap etc.

On your Shopify dashboard, go to the section Domain names And click Manage, on the line of the main domain:

go to the Domain names section
Then go to DNS settings :
DNS settings
Then Change nameservers at the bottom :
Change nameservers
In the window that opens, choose Use custom nameservers :
Use custom nameservers
Go back to the Cloudflare page that we had set aside and replace the values ​​present like this:
Replace the values ​​present like this
Which ultimately gives:
Which ultimately gives
Save and the connection with the Cloudflare CDN is complete! Now, let's move on to its configuration. I reassure you, the hardest part is done 😉.

Configure Cloudflare to improve speed

On cloudflare, several tabs have appeared, we will go to Speed :

Several tabs appeared

Then configure the 3 sections Automatic minimization, Rocket Loader ™ et AMP Real URL like this and save. 

configure the 3 sections Automatic Minimization, Rocket Loader ™ and AMP Real UR

There you go, it's finally 100% complete. Wait an hour for this to take effect 🚀.

Leave a comment

Please note that comments must be approved before posting