Within the webmaster community there are a always lots of myth floating around the internet. So when a non-technical person is thinking about starting his new business-website or blog, he reads these myths and hopes that it will makes his site lightning fast. But the reality is way different than what it seems. Almost all the CDN (Content Delivery Network) companies make you believe that adding their CDN service on your website will instantly supercharge your website and make it load at a lightning fast speed. But you see, this claim is not entirely true. In fact, there are many scenarios where it is wiser to not opt for CDN and invest that money in some other part of your business.

So, despite the magical believe in CDN amongst most people, today I will share 4 situations in which you should concentrate on the other part of your business/website rather than paying for CDN. This will help you understand whether or not you need CDN for your site. At the end I will also share a speed test result with and without CDN enabled, so that you guys can get a clearer picture. But to explain the situations first you need to understand that CDN is not a magical service to make your site instantly fast. Now you need to understand what a CDN is and how it helps.

So, what is a CDN?

CDN stands for Content Delivery Network. In short, it is a deep network of super powerful servers located at various parts of the world, that wil send you the static content from your website from the nearest server with the lowest possible latency. Generally, if you have a normal web hosting (let’s say the server is located at Chicago, US), all of your website’s files are stored on that server. Now when someone requests for a page of that website, the server has to send all the static resource files (like image, css, js files), while also having to execute all of your dynamic programming (like PHP), to generate a normal static HTML file. After this, the server sends all those files to the client who requested for them. Let’s take a look at this basic diagram to understand it easily.

General Server Response

General Server Response

Now, when the CDN comes into the story the entire process gets changed. So, when a user first visits a CDN enabled site, the files get delivered from the actual host server, so the site might load at its normal speed. After a few hits from the similar region, the nearest CDN server stores all the static files (like image, css, js etc.) to that superfast CDN node. Now from this point on all those static files will get delivered directly from the CDN server (which is physically much closer to you), reducing the latency and the nodes are very fast too. Here is a quick diagram about how a CDN enabled website works.

Server Response with CDN

Server Response with CDN

So, now as you can see having a CDN on your site will help visitors who are farther from your actual server location to receive the static files from a CDN node closest to their location at a low latency and high speed. Also it will reduce a bit of load on your actual server too, since most of your static files will get cached by CDN servers all around the world. But the dynamic contents will still be provided by your actual servers only.

Most people have a misconception that CDN servers are only able to cache and deliver static contents, but that is not true. CDN servers are just like any other normal server but both the hardware and software of those servers are extremely optimized to make sure they deliver a lightning fast performance. So, just like any normal server CDN servers can cache dynamic contents too, but it is extremely complicated to implement and sometimes doesn’t work well with various plugins or CMSs. That is why most people only use CDN for delivering their static files all around the world at a super-fast speed.


So, now as we have discussed about what is CDN and how does it work, it is now time to discuss about the situations where having CDN on your site will not make much difference from the perspective of your user’s experience.

CDN doesn’t help much to Local Audience targeted sites

There are basically two types of website lives on the internet. One with a global audience target and the other with a local audience target. For example: Blogs generally target a global audience, as people from around the world may be interested in the same content. On the other hand, there are many business sites and blogs which targets to a specific region or country. The website of a local optometrist will only be relevant for people from the same city or province or at maximum people from the same country. Generally, a person from Australia will not book an appointment for an optometrist located in Canada.

There are also many blogs that right about a specific region or may be a school soccer team. There can be many business websites too who targets only a specific region (within a country) and not the entire world. For this kind of sites CDN is nothing but a waste of money.

Let’s say the server you have for the optometrist site is located at Chicago and people from New York visit it the most. You might think, if I get a CDN for my site, the static files will gets delivered from the CDN node at New York and the files need not to travel from Chicago to New York every time. But in reality, the fraction of second that will be saved by doing this is completely unnoticeable and you will end up paying for something you will not need.

CDN will not help much for slow web hosting

As I said above, CDN mostly handle your static files, but the dynamic contents (generated by PHP) is still being handled by your server itself. So, unless your server quickly executes the dynamic files and sends the generated HTML to the browser, CDN enabled static files have to wait for the HTML to arrive. This will eventually create a slow user experience instead of baking your website lightning fast. So, I highly recommend you to get a good hosting first, like what Bigscoots or Siteground provides, before thinking about CDN.

CDN will not help for sites with less static content

Generally, if your site doesn’t have much static contents (css, js, images etc.) in it and most of the stuff is generated dynamically, then CDN won’t be much help to you for speeding up your site. As most of the data of your site needs to be generated by your actual server before sending out to the user, I think it is wiser to concentrate on a highly optimized faster server, rather than on CDN.

CDN doesn’t help for badly programmed websites

As I stated above, CDN is a content delivery network. It makes sure the static content of your site is received by the client faster. That’s all. CDN has nothing to do with making your website rendering faster. One of the major problem with fancy websites is that they have been programmed very badly. Especially in the javascript (jQuery is part of javascript family) and css department. You see no matter how fast the static contents of your site gets loaded, if you have javascript or css directives that blocks rendering, then you are going to have a relatively slow user experience.

Try to use as little JavaScript as possible in your website. Do not use any JavaScript triggered element above the fold, if you can help it. The less javascript objects you use, the faster your site will load in terms of rendering. Always load all (or as much as possible) of your javascript files at the end of the HTML, just before the closing <body /> tag.

The same principal goes to CSS. Use as little css files as possible and stay away from the css @import directive. I know these are very hard rules to follow in CMS like WordPress, as css and js files get included all the time by various plugins along with themes. This is one of the major problem with multipurpose themes on various theme store like themeforest. These themes come with tons of different features which might be useless to most people, but unfortunately they don’t program their theme to include certain css or js files only when they are needed.


Beside all these situations, if you have a website which targeted towards a global audience and also runs on a fast hosting environment, I will highly recommend you to try out CDN for your site. As it will reduce the load time of your site for the people who live far away from your server’s physical location.

How much speed can be increased with CDN? Is it really beneficial to you?

If your website does not fall under the above 4 situations, CDN can really reduce your website’s pageload time, giving the a faster user-experience. Here is the load test comparison result (with and without CDN) for one of my client’s site. Before you look at the site load time result, here are a few things you need to consider:

  • The site has been hosted on a super fast highly optimized SSD server located at Chicago, USA.
  • The site uses many heavy (resource hogging) plugins like woocommerce, bbpress, buddypress etc.
  • The site is highly dependent of JavaScript and jQuery scripts which blocks rendering. So, the overall render completing time is a big number.
  • The CDN that has been used for the testing is KeyCDN (a review is coming soon).

So, let’s look at the load test result now:

Test LocationWithout CDN Load TimeWith CDN Load TimeTime Difference
New York, USA3.62 sec2.91 sec710 ms
Dallas, TX, USA3.75 sec2.90 sec850 ms
Melbourne, AU10.30 sec5.80 sec4.5 sec
San Jose, USA3.87 sec3.24 sec630 ms
Stockholm, Sweden5.85 sec3.97 sec1.88 sec
* all the load test has been done using Pingdom Tools.

So, as you can see, the locations within USA itself don’t have much load difference as the actual server is in the USA itself, but when I started testing locations far away from USA, the load time difference can be clearly seen and this is where CDN excels the most. So, unless you have global audience need, I don’t think you will get much benefit from using CDN.

Conclusion

CDN is not for every website out there. If you do not have a high amount of daily global audience, the money you will be paying for a quality paid CDN service, will not yield much benefit for you or your business. Also even if you have a good global audience, make sure you have hosted your site with good hosts like Bigscoots or Siteground so that the server is capable enough to send the dynamic files super-fast to the client. In the end to make sure you receive the best possible outcome with CDN, ensure that your website is fully optimized.

Feedback

Do you guys use CDN? If yes which CDN provider you prefer most and why? Also do you agree with the 4 situations I’ve mentioned above? I would love to hear your thoughts on this and continue this conversation in the comment section below. Feel free to share your thoughts.

You can also connect with me via twitter @iSaumya. If you like this post, please don’t forget to share it with others who might enjoy reading it. Also if you have any other ideas or request about future posts, you can let me know in the comment section below or via twitter.

Published by Saumya Majumder

Passionate, Hard Worker. Love to develop new things, Singing Songs, playing computer Action Games, tweaking with computer languages, Riding Bikes, Love long driving, love books, web & Photography. You can follow me on twitter @iSaumya

Subscribe To My Newsletter

Subscribe To My Newsletter

Join my mailing list to get meaningful content, useful information, how-tos, tricks, tips for webmaster, bloggers and entrepreneurs to rise and profit in your online business.

You are almost there! Just check your Inbox to confirm the Subscription & you are all set.

Shares

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close