What Is a CDN? Understanding Content Delivery Networks

Learn More About HubSpot's Built-In CDN
Anna Fitzgerald
Anna Fitzgerald

Updated:

Published:

Online consumers are known to abandon web pages with slow load times — that means you need your website or mobile app to be fast to delight visitors. To speed up your web assets, you need a content delivery network (CDN).

What Is a CDN? Understanding Content Delivery Networks

What is a content delivery network?

It's one acronym in a sea of marketing acronyms that all relate to the inner workings of your business.

To understand what a CDN is, imagine you have a website hosted on a server in Denver, Colorado. We don't often think about websites as being in a physical location because the internet makes it seem everywhere, but a website and all of its content assets have to be based in what's called an origin server.

So how do those assets get routed from the origin server in Denver to a visitor's browser in Boulder? Or Boston? Or Tokyo? You might have guessed the answer is a CDN, but still don't know what it is or how it works.

Speed Up Your Website with HubSpot's Built-In CDN

In this post, we'll go over the following:

To understand how, let's return to our website in Denver, Colorado. Every time a visitor types your site address into their browser, the browser has to call upon your origin server to send, assemble, and display your content assets on their screen. That's not so hard if the visitor is in Boulder, Colorado.

But it becomes more challenging if you have visitors from Boulder, Boston, and Tokyo, for example. Not only is that a lot of distance for your content to travel, but it also requires very different routing paths.

whatisacdn

Source

This is where a CDN comes to the rescue. Rather than have one server send content from Denver to Boulder, Boston, and Tokyo, the CDN will tap different servers in the network that are closest to each visitor to deliver the assets.

What is the primary purpose of a content delivery network?

The primary purpose of a content delivery network is to deliver any type of digital content efficiently and securely to visitors, no matter where they are in the world and no matter what type of device they’re using.

CDN infographic

Source

To do so, CDNs have to take two major factors into consideration. The first is geographical distance. When a visitor accesses your website — whether they're from Boulder, Boston, or Tokyo — you want the server closest to them to deliver and display your website. That's because the closer the server is to the user geographically, the faster the content will be delivered.

The second factor a CDN has to consider is traffic.

Imagine that you post a blog on your website and it goes viral. Or imagine there's a more nefarious reason for a rush of external requests like a DoS attack. Any surge of traffic to your website will put a lot of strain on your server.

Without a CDN, this might cause your server to go offline and prevent visitors from accessing your site. With a CDN, however, this traffic will be distributed across multiple servers, reducing the strain on your origin server and keeping your site online.

For these reasons, CDNs are essential for improving the speed and overall performance of websites that have a global reach as well as websites that experience surges in traffic or high traffic regularly.

Now that we understand the definition and purpose of a CDN, let's take a closer look at how it actually works.

How does a CDN work?

Once a visitor accesses your website and the server closest to them delivers and displays your website, that server makes a copy of your web assets.

These cached files — which include your HTML pages, javascript files, stylesheets, images, and videos — are then stored on solid-state and hard-disk drives (SSD and HDD) or in rahttps://kinsta.com/blog/what-is-ssd/ndom-access memory (RAM) for safekeeping.

That way, when another visitor in the same part of the world tries to access your website, the CDN can redirect the request from the origin server to the server closest to them. That server can then deliver the cached content much more quickly because it has less distance to travel.

This is all imperceptible to the end-user, so they simply see the page loading as expected and benefit from reduced wait times without getting bogged down in the details.

Beyond accelerating content delivery, CDNs can also help protect your site because they are located in front of your backend server.

From this position in your network perimeter, they can act as a bouncer for your site, blocking attacks on your website and controlling the flow of incoming traffic so that the load on each server is balanced.

CDN

Source

How to Use a Content Delivery Network

There are two ways you can use a CDN. You can choose a website building platform with a built-in CDN, or you can purchase one from a CDN vendor.

If you purchase one from a third-party vendor, you'll have to make it the default inbound gateway for all incoming traffic by modifying the DNS configurations of your root domain and subdomains. That'll ensure all visitors are routed to your CDN instead of your server.

This might sound complicated, but most vendors offer step-by-step tutorials or hands-on assistance to simplify the process.

Below we'll take a look at a few different options for building a site with a CDN.

Hosting with CDN

A web hosting service enables you to host your website while a CDN improves website performance by increasing content delivery speed. A two-in-one platform where you can both host your website and leverage CDN capabilities makes your life easier. HubSpot’s Content Hub features a free, built-in CDN. With HubSpot’s CDN, you won’t have to worry about setting up additional tools since it is baked into the web hosting service. This frees up your time to focus on building a great web experience for visitors.

Best CDNs

CDNs can reduce latency, increase page speed, minimize bandwidth consumption, and block data scrapers and other forms of spammers targeting your site. To improve the speed and security of your site, choose a platform with a built-in CDN or a CDN vendor. Let's look at a few options below.

1. HubSpot's Content Hub

Screen Shot 2022-03-15 at 2Get started with free hosting and CDN

If you use Content Hub to host your website, you'll already have a built-in CDN. There's no configuration, setup, or additional accounts required, and you won't have to purchase and install one from a third-party provider.

With this CDN, not only will your content be delivered quickly, securely, and with less latency around the globe — you'll also be able to track the volume of potential attacks or probes into site vulnerabilities to keep your CMS hosted website, blogs, and landing pages safe.

That means you can focus on building a great site without worrying about distribution, cache invalidation, or online attacks.

Feature highlights:

  • Built into Content Hub
  • Fast page load times across all devices and global users

Learn more about Content Hub's other out-of-the-box security features, including enterprise-class web application firewall, SSL, and SSO memberships.

2. Cloudflare CDN

CDN · Cloudflare Reference Architecture docs

Source

Cloudflare has a global network of data centers that spans 285 cities in more than 100 countries and supports over 26 million internet properties. By combining data with machine learning, Cloudflare sends content requests along the fastest and most reliable paths on its network.

Cloudflare offers a free plan as well as three paid plans for small and enterprise businesses, starting at $20 per month.

Feature highlights:

  • Web filtering to block bots
  • Smart image optimization

3. Amazon CloudFront

Amazon CloudFront

Source

Amazon CloudFront is a CDN service that securely delivers data, videos, applications, and APIs to customers across the globe. Known for its low latency and high transfer speeds, Amazon CloudFront is used by Hulu, Dow Jones, Condé Nast, and other major companies to deliver solid streaming or user experiences and manage spikes in traffic and security.

Amazon offers a pay-as-you-go pricing model with no upfront fees or required long-term contracts.

Feature highlights:

  • Sizable network
  • Regional edge caches

4. Google Cloud CDN

Google Cloud CDN

Source

Google Cloud CDN uses Google’s global network of 90 data centers internationally. Pull content from HTTP-capable origins including Compute Engine, Cloud Storage and Google Kubernetes Engine backends. Additionally, the CDN comes with a free SSL certificate.

Google offers a free trial with a $300 credit and a pay-as-you-go pricing plan.

Feature highlights:

  • Origin and backend support
  • Caching

Speed Up and Grow Your Site

Looking for accelerated web performance, DDoS protection, data loss prevention, and bot mitigation? Try a CDN.

Whether you're using a platform with a built-in CDN or looking to incorporate one from a third-party vendor, such a service can enable you to create or grow into a high-traffic website that reaches a global audience.

Editor's note: This post was originally published in July 2014 and has been updated for comprehensiveness.

New Call-to-action

 

Topics: Web Hosting

Related Articles

Speed Up Your Website with HubSpot's Built-In CDN

GET HUBSPOT'S BUILT-IN CDN

CMS Hub is flexible for marketers, powerful for developers, and gives customers a personalized, secure experience

START FREE OR GET A DEMO