CDN (Content Delivery Network)

Wikipedia defines a CDN as a content delivery network which is an overlay network of computers containing copies of data, located at various points in a network in order to maximize bandwidth for customer to access the data over the network. A client accesses a copy of the information about the customer, as opposed to all clients accessing the same central server, to avoid funnels near that server.

There are many providers of this service, and we use CloudFlare. Besides providing good service, they also offer a free version. We will now see how we can use a CDN to improve the load time of our website and we will illustrate using this provider as an example.



– To set up a CDN we have to access our DNS domain, because we have to implement some changes to direct traffic to the service provider.

– The free version of some CDN providers, does not support its use for https pages, so if we use this protocol, we have to use a paid version.

– CDN providers offer a cache service of the files from our website. This greatly reduces the loading time of the website. However, if our website has a lot of dynamic content, we should set a less aggressive “caching” option because otherwise users can see older versions of our dynamic pages.

– If you are working on programming tasks on your website, it is advisable to temporarily disconnect the CDN, as that can sometimes interfere with the visualization of the changes we are making.

– The main advantages of using a CDN include the following:

Reducing load time of our pages, improving our SEO and usability of our website.

Reducing transfer of data from our server (as most content will be served through the CDN).

Decreasing the possibility of a hacker attack on our website.



The first step is to create an account on the CDN provider, in our case CloudFlare. Once the account is created, we simply add our domain name and the system will do a scan from our records.

cloudflare-scanningThe system tells us that we must change the DNS settings in the domain:

dns-cloufllareTo do this, we will go to our domain provider, and make the appropriate changes. To verify that we have made ​​the changes correctly, we can use the webpagetest tool that will show us whether or not we use the CDN to serve the content of our website.

webpagetestWe turn now to configure  CloudFlare service parameters.

cloudflare-settingsThe configuration that we use is:

Settings overview

Security profile: Medium

Performance profile:Custom

Automatic IPv6:Off

Pseudo IPv4:Off

Always online:On

Client maximum upload:100MB

Security settings

Security profile:Medium

Basic protection level:Medium

E-nail obfuscation:On

Server side exclude:On


Performance settings

Performance profile:Custom

Cachin level:Basic

Minimum expire TTL:8 days

Auto minify:Js,css,html

Rocket loader:Automatic

Finally, you should have in mind the following:

– We can temporarily stop the service at any time (e.g. if we are changing our website code).


– CloudFlare service also offers interesting statistics (also free).



Additional Resources

For any additional questions about CloudFlare, we advise you visit the following address:


Leave A Response

* Denotes Required Field