Content Delivery Networks (CDN)

How it works

A CDN is a very important part of modern-day websites, it improves the overall experience of users that visit a website, basically making the web page load a lot faster, most users these days don't have the patience to sit around and wait for your webpage to load for ages, they drop off or find an alternative. CDNs are widely used today, chances are this current website you are on uses CDNs to make your experience better.

A CDN is a network of computers that are geographically distributed to provide faster content delivery to end users. This content includes HTML pages, CSS stylesheets, JavaScript, images etc. With the use of CDN, your website would load up all assets considerably faster. In this post, we'll discuss how CDNs work and their benefits.

How it works

Originally, before using a CDN, when a user visits a website, before any content is displayed, a request has to travel to find the website's web server, which might be on the other side of the world to fetch the content to be displayed, this might take a few seconds, during this time is the user is there, waiting for content to be displayed. This may not always be very slow, the user may not even notice it, but it can be optimized and made even faster, hence the introduction of CDNs.

With CDNs, these contents are stored geographically close to the user, so the request doesn't have to travel far before the content is returned, consequently reducing load times. Thereby reducing latency and increasing the performance of the website.

How do CDNs store these assets? CDNs internally use caches to store the assets, and we know caches provide a fast and efficient way to store and retrieve data.

A CDN consists of a bunch of nodes (points of presence) scattered geographically, each of these nodes has a cache that stores contents and delivers them to users that are located close to it.


Improved performance: CDNs can significantly improve the performance of websites and web applications by reducing latency and delivering content from servers that are closer to the user's location.

Increased availability: CDNs can help to improve the availability of websites and web applications by distributing content across a global network of servers. This means that if one server goes down, users can still access the content from another server.

Reduced bandwidth costs: CDNs can help to reduce bandwidth costs by offloading traffic from origin servers. This is especially beneficial for businesses that deliver a lot of media content, such as images and videos.

Improved security: CDNs can help to improve the security of websites and web applications by providing features such as denial-of-service (DoS) attack protection and web application firewall (WAF) protection.


CDNs are very important these days, if you value your user's experience while using your website, you should consider CDNs if you are not using it already.