Welcome to the StackPath CDN Quickstart Guide! This guide aims to get you up and running on our CDN as quickly and painlessly as possible.
It's important to note that this guide only scratches the surface of what you can do with our platform - but if your goal is to go from not-having-a-CDN to using StackPath's CDN as fast as possible without all the fuss or dry technical reading - this guide is for you!
Let's get started! First things first is we need to create a Site in the Stack Path portal.
What is a Site?
A site is your window into StackPath configuration options for each website. Here you can manage how StackPath pulls content from your Origin and how content is delivered to your end-users. Here's how to get started.
Before setting up a site you'll need to have a StackPath account and at least one Stack that includes any StackPath service.
Creating a Site
- Log into the StackPath Control Portal and navigate to the Sites section. Select Create Site.
- Enter the domain that will be delivering CDN assets from. In most cases, this is simply the website's URL. Under Available Services, tick the box for CDN (You will be able to add more at any time). Once complete, select Continue.
- Hostname/IP address: The Hostname/IP Address field will auto-fill by querying DNS records for an A- record belonging to the domain name entered in Step 2. If you are unsure, you can typically verify with your hosting that this IP is the correct address for your Webserver. The hostname/IP address of your Origin can be changed at any time under Sites > Settings > Origin Address.
- Origin Authentication: StackPath allows you to select the authentication mode required to connect to your Origin. None will proxy no authentication to the origin, while Basic will provide the option for inputting a username and password, to be passed through basic HTTP Authentication, if required by your origin server. Authentication can be changed at any time under Sites > Settings > Origin Authentication.
- Select Continue
- At this time, you will be presented with your CDN Site in the Control Panel. The Edge Address presented to you is your site’s access to CDN service. Please note that the Edge Address is used for both HTTP and HTTPS configurations.
- To test that the CDN can communicate with your server, try pasting the Edge Address into a browser, it should direct to the domain you entered in Step 2.
Congratulations! You have just configured your StackPath CDN Site and you are now ready to move on to Step 2 of this guide!
You can continue reading this guide for troubleshooting information and to learn more about specific features included in CDN Sites.
Edge Address Errors
OH NO! Going to my Edge Address generates an error!
Not to fear, below are the two most common issues you might run into and what to look at to fix them:
- Error 404 Not Found
- Your Origin IP set in step 4 is incorrect. Please verify the correct IP address for your server and repeat this guide.
- Error 502 Bad Gateway/504 Gateway Timeout
- Please ensure that your hosting provider is not blocking StackPath IP space. If they are, then you may refer to this article for our list of IP blocks to be whitelisted at your hosting provider or on your server.
- If your hosting provider is not blocking anf you are still getting this error when visiting your edge address, please contact support and we will assist you in tracking down the issue.
Site Features
Now that you have created your CDN site, let's examine a few of the features you will need to be familiar with to get set up. You will find these along the side bar of your StackPath Control Panel:
- Overview
- Basic Analytics for your CDN site.
- Bandwidth (From the CDN to end-users & from the CDN to Origin)
- Requests (CDN to end-users & CDN to Origin)
- Bandwidth by Geolocation
- Cache hit Ratio by Request and Mb/second
- Analytics
- A more granular view into the metrics for your sites
- Settings
- Configuration settings for StackPath to communicate with your Origin server. This is the panel to configure how Stackpath retrieves content from a website's host. It is essential to set the correct origin address and protocol, and host header
- Delivery domains are specified here. These domains are additionally included to fulfill requests with the site's cached content.
- CDN
- Configuration settings for how the CDN handles caching a website's files. Here a website's cache can be refreshed, caching time to live set can be set, or site optimization can be configured.
- WAF
- Configuration settings for the StackPath WAF, if enabled for this site. This tab contains all of the WAF Policies and DDOS Protection thresholds configurable for the StackPath WAF.
- Firewall
- The WAF's basic IP Firewall. You can use this tab to Allow or Block any singular IP or IP range when the StackPath WAF is enabled for this site.
- Scripts
- Contains the settings and scripts being used via our Serverless Scripting offering.
- EdgeSSL
- If a website is using HTTPS, there are three options to choose from under EdgeSSL.
- Free SSL certificate with Edge Address
- Free SSL certificate with Custom domain
- Upload your own SSL Certificate
- If a website is using HTTPS, there are three options to choose from under EdgeSSL.
- EdgeRules
- Setup conditional statements or select preconfigured rules for how your content is managed by the CDN, or Requests are handled by the WAF.
For a more in-depth look at the settings available to you, please visit our StackPath Settings Explained article after completing this quick-start guide. (Link will open in a new tab)
Move on to Step 2
Now that we have gotten our CDN Site created, we are now ready to move on to the next step - CDN Integration Guide Step 2: Setting up your SSL certificate.