Arranging a CDN is not always easy. As a rule, it requires making changes to the website code. It may take a lot of effort to replace the links to the static content of your website by adding the domain of the provided CDN resources to them.
How does a CDN work?
A CDN (content delivery network) is an effective tool to speed up your website.
The delivery network uses geographically distributed servers to reduce the actual distance to the user. A shorter distance allows for faster downloading of files from your website. This means that images, CSS, HTML, and JS files will first be uploaded to the nearest cache server, and only then transferred to the user upon request.
Setting up a CDN for a website
In most cases, in order for the client browser to access the files uploaded to the CDN server, instead of the files on the origin server, it is necessary to replace the links in the website code.
Usually, the links to the origin server look like this:
https://gcore.com/image.jpg https://gcore.com/style.css https://gcore.com/script.js
To redirect to the cache server, the modified links to the file should look something like this:
https://cdn.gcore.com/image.jpg https://cdn.gcore.com/style.css https://cdn.gcore.com/script.js
However, there are ready-made solutions that allow you to avoid making such changes to the code and start distributing content via CDN literally 15 minutes after connection.
CDN plugins for CMS
Users of popular CMS (WordPress, Joomla, etc.) usually deal with this task with the help of CDN plugins. They provide the user with a convenient interface for quickly replacing links without diving into the website code.
DNS hosting integrated with CDN
Another solution to simplify configuration is to use NS servers to route traffic through the CDN. However, not all CDN providers offer this opportunity.
At Gcore, we have successfully integrated DNS hosting and the capabilities of our CDN, providing the user with a simple and clear configuration interface. It not only allows our clients to direct traffic through our global network, but also provides a number of advantages:
- Not only static but also dynamic content is cached and delivered faster.
- Static and dynamic website content is protected from DDoS attacks thanks to a network of caching servers (L3 and L4).
Additional advantages
Thanks to the functionality of our network, visitors to your website will have access via the HTTP/2 protocol and a secure SSL connection. This is possible by default, even if your web server does not have an SSL certificate or support HTTP/2.
About our DNS Hosting
We have one of the fastest DNS hosting services in the world, which allows us to look for an IP address of a requested domain name (DNS resolution) with minimal delays.
Gcore DNS Hosting is provided on the basis of Anycast and GeoDNS technologies, which allows it to quickly find the required server and lay the optimal route to it. Fast DNS reduces the response time on the global network to 30 ms.
The free DNS hosting plan provides 10 million queries per month, 1,500 records, 25 zones, and a TTL within 20 seconds.