CDN – what is it and how does it work?

The creation of a website is one thing, but its proper optimization is a completely different topic, which we cannot forget about – especially if we care about the positive reception of the site by Internet users and high positions in Google. When it comes to optimization, we should pay special attention to Site load time, as it is relatively easy to improve. There are several ways to do this, and one of them is to use CDN. What exactly is it and why is it worth using this solution on your website?

CDN – what the acronym stands for?

CDN stands for Content Delivery Network, what it means in translation content distribution network. Simply put, these are servers located in different places around the world that store copies of the elements that make up our website. Using a CDN will make your website faster, but it will also increase its security, mainly by mitigating the effects of possible attacks like DDoS.

How Content Delivery Network works

The main purpose of a CDN is to provide content to the user based on their location. Such a solution makes sure that the Internet user, when visiting our site, will receive a large part of its content from the server that is located closest to him. Thanks to this, the elements of the website have a shorter distance to cover, and this directly translates into its faster loading. Of course, the CDN service does not affect in any way the speed of generating a page on the server, but only speeds it up.

How it looks like in practice?

Let’s assume that our main server is located in Warsaw, and the user will visit the site from another country, for example. USA. In a normal situation, it receives all the data directly from the main server, and then the distance that the information must cover is really considerable. This, of course, makes the loading time of the site much longer for such a foreign visitor than for a person located closer to the server.

no cdn

Unfortunately, this can strongly discourage people to stay on the site, but this problem can be solved by using CDN. Content distribution network thanks to additional nodes makes it possible for an Internet user to download static elements of a website by connecting to a closer server instead of connecting to the main one. Of course, an important aspect here will be the location of such servers, so that all visitors to the site have at least one of them relatively close.

active cdn

Who a CDN is for

It would seem that CDN is only applicable to sites with global traffic, but this is not true. In fact, these are the ones that benefit the most, but load time reductions can also be seen on sites that primarily serve local traffic. Provided, of course, that such servers are properly deployed.

Let us use an example. Our main server is located in Gdansk, but the user accesses the site from Krakow. If there is a CDN node near him, the page will load faster than if he were to connect directly to the server in Gdansk. Although the differences are not as big as in the case of foreign traffic, but they are still significant, because the current Internet user is usually impatient. Here every second counts, and waiting too long will most likely make you abandon the visit and use another site.

How to enable CDN on your own website

If you want to enable CDN on your site, first of all you have to choose a company which offers such a service. There are many of them on the internet, and basic configuration is not too complicated. However, it is worth noting that instead of paying separately for web hosting and CDN, it is better to simply choose a company, which has this service already in the hosting price. In Poland one of the best offers has nazwa.pl, to which we can move the site completely free of charge.

nazwa.pl

Company name.pl besides cloud hosting, which is faster than traditional one, also offers additional services. These are the m.in.: automatic image conversion and DNS Anycast, which makes the site even faster.

Advantages of using CDN

  • Faster page load times – not only by shortening the distance between the user and the server, but also because CDN is optimised for sending static content. Thanks to this TTFB (server response time) is also much shorter in comparison to a standard server.
  • Greater security – CDN mitigates the effects of DDoS, one of the most popular types of attack, which blocks the server using all available Internet connection resources. Like? When an attack occurs, the traffic is directed to CDN servers, which reduces the risk of overload. What’s more, they usually have additional security features that further increase protection.
  • Lower transfer usage – data downloaded from the CDN do not count towards the limit, which can be important especially for shared hosting and cheap servers.
  • Greater stability – thanks to the use of multiple servers, a failure of one of them does not cause the website to stop working. In case of unavailability, the request is sent to another, closest server.

Why page speed is important?

page speed and loading time

Fast website has positive influence on its reception by visitors and its conversion rate. If the site takes too long to load, the vast majority of users will unfortunately leave without any interaction, and we will lose a potential customer.

We cannot forget about the influence of the website loading time on SEO activities, as it is one of the ranking factors.

Summary

Using Content Delivery Network is a good way to reduce page load time, increase security and reduce maintenance costs. Although global sites benefit the most, a CDN will also work well for local sites – especially if you use a company that has several such servers in the country where most of your traffic originates. This is the reason why content delivery networks are so popular and leading websites use them so eagerly.