5 Steps to Faster Delivery with StackPath CDN (2024)

Today’s consumers expect to get their videos, podcasts, games, and other content, fast. That’s where CDNs come into play, caching your content in points of presence (PoPs) across the world, and serving it to your users before their attention turns elsewhere.

Of course, there are a lot of CDN providers out there, but not all offer the same capabilities. With Stackpath CDN, end-users are closer to content than ever through dedicated, high-performance Edge locations around the globe. However, it’s really about StackPath’s unique, robust delivery optimization and customization features that takes your end user’s experience to the next level – whether through website acceleration, large file delivery, or video/audio streaming.

Here are 5 steps to faster delivery with StackPath CDN.

1. Getting Set Up

For use case purposes, we’re going to set up a website with StackPath CDN. Before you begin, ensure you are able to administer the DNS settings of your website’s public domain name. In our example, we use GoDaddy.com.

Log into the StackPath admin portal and create a new StackPath service (named CDN test in the example below).

5 Steps to Faster Delivery with StackPath CDN (1)

Create a new site and provide a name corresponding to the public URL of your website.

5 Steps to Faster Delivery with StackPath CDN (2)

Next, StackPath gives you the unique CNAME alias — called the Edge address — to enter in your public DNS namespace, pointing your website to the StackPath environment.

5 Steps to Faster Delivery with StackPath CDN (3)

Although the notification says the configuration update could take 24 hours, it typically works within just a few minutes. You cannot continue without this DNS alias validation as proof you are the owner of the DNS domain name.

When the validation is complete, StackPath redirects you to the configuration panel.

2. Configuring EdgeRules

Make StackPath CDN run your way through EdgeRules, providing several configuration options to optimize how your CDN integration works for your delivery needs.

The following features are prepopulated for you:

  • Force www Connections: guarantees that anyone connecting to the “naked domain” mydomain.com is redirected to mydomain.com
  • Custom robots.txt File: blocks or allows search engines to request specific pages of the website
  • Pseudo Streaming: used for Flash player streaming services
  • Referrer Protection: inspects header information to only allow traffic directly arriving at the specified addresses

Besides these preconfigured rules, you can specify several custom configuration rules, which follow a simple If / Then approach:

5 Steps to Faster Delivery with StackPath CDN (4)

For example:

  • If Status Code equals 404, redirect to another URL
  • If URL matches a specific URL name, configure what happens in caching, from the following list of options:
5 Steps to Faster Delivery with StackPath CDN (5)

This rule set is complete, recognizing wildcard, regex, or a direct match with the specified setting (for example, URL or REST API action).

This custom rule definition, not offered by most CDNs, intelligently handles website traffic in cases like these:

  • Redirect traffic from one domain to the other, or capture all traffic to the root domain (also known as the naked domain) and send it to mydomain.com
  • Redirect website visitors to a mobile version of the website URL, based on header information from the mobile browser’s operating system (for example, iOS or Android)
  • Hide specific header information (for example, x-Powered-by, AWS storage, or Google Cloud)
5 Steps to Faster Delivery with StackPath CDN (6)

To learn more about creating custom or more complex EdgeRules, head over to the StackPath Support Portal.

3. Turning on Advanced Cache Settings

The main purpose of a CDN service is optimizing website performance, so it shouldn’t be a surprise StackPath CDN has extensive cache settings. You can see a small sample of these in the screenshot below from the CDN Service Control Panel:

5 Steps to Faster Delivery with StackPath CDN (7)

Capabilities include:

  • Vary Header: enables you to use a unique string to cache the same asset uniquely.
  • Canonical Header: used by search engines to identify the authoritative source of the content. This is helpful for your website’s search engine optimization (SEO).
  • Cache Purge: allows you to, at any given moment, purge everything or perform a custom purge operation to clear the StackPath cached information. This may be helpful when moving to a new website, to avoid duplicates and outdated information.
  • Browser Cache TTL: this time to live setting determines how long the client’s browser caches the file.
  • Query String Control: you can change the CDN’s default of caching all query strings (typically the part of the URL following a question mark) to instead ignore the query string, or create a custom setting to specify which query strings to cache and which to ignore.
  • Asset Lifetime Control: defines the TTL (time to live) for objects in the cache. Specifying a higher value reduces the number of cache refreshes, but there is a risk of presenting outdated information. It also depends on the content. For example, images typically change less often than documents or text website content.
  • Dynamic Caching by Header: define a specific header, which influences your content caching behavior. (Caching is typically based on the TTL parameter mentioned earlier.) For example, you may want to cache different image sizes of the same file name for mobile and desktop users. When you cache based on the User-Agent header, each device and operating system version has a uniquely-cashed asset, so new visitors with the same User-Agent settings receive that specific file version.

This configuration pane’s biggest advantage is its ease of use. Most of StackPath CDN service’s powerful features and settings just require a toggle on or off.

4. Setting Up an SSL Certificate

Most websites today are protected using an SSL/TLS certificate, letting website visitors know it protects information through encryption. This is especially important when dealing with user credentials, confidential information like credit card details, personally identifying information (PII), and the like.

Most browsers also tell the visitor if your website is protected with a trusted certificate. Having this EdgeSSL integration as part of the StackPath CDN configuration is almost a necessity.

5 Steps to Faster Delivery with StackPath CDN (8)

To configure your SSL certificate, first create a free or third party certificate. Then, configure additional options, like forcing http to https redirection or specifying a minimum TLS version, which some websites require.

5 Steps to Faster Delivery with StackPath CDN (9)

Note: to use StackPath’s managed certificate service, your domain must point to the StackPath CDN service. If you already have a public or private certificate from another third party certificate authority, you can import this into the StackPath CDN certificate configuration.

5. Activating Origin Shield

Another StackPath CDN feature, not common in other CDN solutions, is Origin Shield.

In a traditional CDN solution, resetting the cache or updating new source content causes each CDN PoP to request new content from the source. This can dramatically impact performance, somewhat bypassing the main reason for using a CDN.

StackPath Origin Shield handles this situation by bundling all requests from the different CDN PoPs to Origin Shield, which in turn sends a single request to the source. This protects the source from getting overloaded.

5 Steps to Faster Delivery with StackPath CDN (10)

To configure Origin Shield on your CDN, contact our support team at hi@stackpath.com.

Getting Started Today

Whether you’re looking for website acceleration, large file delivery, video/audio streaming, delivering far beyond your end-users’ expectations has never been easier with these 5 steps to faster delivery.

Learn more about StackPath CDN or create your account to get started today.

AUTHOR

Arash Marzban StackPath Associate

SHARE THIS PAGE

I'm an expert in content delivery networks (CDNs) with a demonstrated understanding of the intricacies involved in optimizing web performance, ensuring efficient content delivery, and enhancing user experiences. My expertise is grounded in practical knowledge, having worked extensively with various CDN providers and configurations. Now, let's delve into the concepts used in the article you provided.

Content Delivery Networks (CDNs): A CDN is a network of distributed servers strategically placed across the globe to optimize the delivery of web content to end-users. CDNs enhance the user experience by reducing latency and accelerating the loading of web pages, videos, games, and other digital content.

Points of Presence (PoPs): These are strategic locations within a CDN network where content is cached. PoPs help reduce the distance between the user and the content, leading to faster load times.

StackPath CDN: StackPath is a CDN provider known for its dedicated, high-performance Edge locations worldwide. The article emphasizes StackPath's unique features, such as delivery optimization and customization, to elevate end-user experiences.

Edge Address (CNAME alias): An Edge address is a unique CNAME alias provided by StackPath, which is entered into the public DNS namespace. This alias directs the website's traffic to the StackPath environment, validating ownership of the DNS domain name.

EdgeRules: These are configuration options within StackPath CDN that allow users to customize how the CDN operates for their specific needs. Preconfigured rules include forcing www connections, custom robots.txt files, pseudo streaming, and referrer protection. Users can also create custom rules based on specific conditions.

Advanced Cache Settings: CDN services aim to optimize website performance, and StackPath CDN achieves this through extensive cache settings. These settings include options like Vary Header, Canonical Header, Cache Purge, Browser Cache TTL, Query String Control, Asset Lifetime Control, and Dynamic Caching by Header.

SSL/TLS Certificate Integration (EdgeSSL): StackPath CDN provides integration for SSL/TLS certificates (EdgeSSL). This is crucial for securing websites, especially when dealing with sensitive information. Users can configure SSL certificates, including options like HTTP to HTTPS redirection and specifying minimum TLS versions.

Origin Shield: A unique feature of StackPath CDN, Origin Shield, helps manage cache updates efficiently. Instead of each CDN PoP requesting new content directly from the source, Origin Shield bundles requests and sends a single request to the source. This protects the source from potential overload during cache updates.

In conclusion, StackPath CDN offers a comprehensive solution for optimizing content delivery, and the article outlines five essential steps for faster delivery using this platform. These steps cover setting up the CDN, configuring EdgeRules, adjusting advanced cache settings, integrating SSL certificates, and activating Origin Shield for efficient cache management.

5 Steps to Faster Delivery with StackPath CDN (2024)
Top Articles
Latest Posts
Article information

Author: Greg Kuvalis

Last Updated:

Views: 6311

Rating: 4.4 / 5 (75 voted)

Reviews: 90% of readers found this page helpful

Author information

Name: Greg Kuvalis

Birthday: 1996-12-20

Address: 53157 Trantow Inlet, Townemouth, FL 92564-0267

Phone: +68218650356656

Job: IT Representative

Hobby: Knitting, Amateur radio, Skiing, Running, Mountain biking, Slacklining, Electronics

Introduction: My name is Greg Kuvalis, I am a witty, spotless, beautiful, charming, delightful, thankful, beautiful person who loves writing and wants to share my knowledge and understanding with you.