There are many CDN platforms out there but, at the core, each serves the same goal—to make websites faster through utilizing distributed networks of edge servers in locations close to the users accessing them. But once you take a look under the hood, it becomes clear that each CDN platform uses slightly different means to that end.
Many of today’s CDNs do much more than just distribute content—they offer a bunch of other features for improved security, analytics and development. And as content evolves into more dynamic formats and is viewed through a fragmented ecosystem of devices, choosing the right CDN that works best for your specific business and type of content (e.g. static assets vs. dynamic data / JSON, etc) is more important than ever. In this post we will hopefully shed some light on the subject, and compare the two popular CDN platforms Cloudflare and Cloudfront with the Layer0.
Running a fast website is no longer some fancy, superfluous gimmick. In fact, it is becoming a viable element of the SEO arms race. Google has always paid attention to site load speeds and ranked websites based on performance. But now it’s time to take action as we know that from 2021 onwards site speed will be a critical element of SEO ranking.
The consequences of not offering a great experience will soon be felt by many players, especially by operators of eCommerce sites, which tend to be image-rich and have unique features that slow them down like real-time inventory lookups and dynamic pricing. According to Google’s own research, just 100ms improvement to mobile page loads boosts an eCommerce website’s conversion rate by 8.4%. Slow websites will slide down the SERP page and possibly suffer million dollar losses.
The problem with today’s CDNs
The increasing complexity of websites creates its own share of new challenges for CDN providers. CDNs must evolve to support this crazy pace of evolution and provide infrastructure and features that make the new, dynamic and image-heavy pages run quickly and make great browsing experiences possible. Modern CDNs must provide support for richer and more sophisticated content and evolving protocols and formats, while protecting websites from DDoS attacks which are growing in scale and sophistication.
Let’s now have a look at the popular CDNs Cloudflare and Cloudfront as well as the Layer0, and see if they’re up to the challenge.
Cloudflare positions itself as a lower-cost CDN. It offers global presence, unique performance capabilities and is known for a relatively strong focus on security. Cloudflare is user-friendly, easy to set up, affordable, and makes a pledge to meet the future needs of the businesses using it. It can optimize content beyond just static assets and comes with various security features.
Their global CDN infrastructure accelerates the internet applications and mobile experience, ensuring application availability. Lastly, they operate a network of 200 data centers in different countries to reduce the latency and improve the browsing experience for users.
Cloudflare key features
Improved web experience: Rather than sending all the requests from different corners of the world onto a single server, requests are distributed on Cloudflare’s fleet of 200+ distributed servers. This distributed network balances the workload of the servers and keeps the content available to users.
Security. Protects your website from all sorts of online threats, including DDoS attacks .
Site analytics. Cloudflare’s offers analytics features to track the performance of your server. The built-in analytics allow you to keep tabs on your website traffic, but also track the avoided threats, bot traffic and much more.
Advanced WAF: Cloudflare also offers adequate security solutions for enterprise-level websites to combat severe attacks that can degrade the performance of a website. Web Application Firewall rules are automatically updated when security threats are discovered.
24/7 email and phone support is available, but only in the Enterprise plan.
Pros of Cloudflare:
- Offers Argo smart routing
- AutoMinify for smart content optimization
- Web and browser optimization
- SSL/TLS, Web Application Firewall and Cloudflare Access: identity and access management enabling secure application access without a VPN
- Free shared SSL certificate
- Unlimited and unmetered bandwidth consumption
- Image optimization with Polish
- PCI compliance and prioritizes email support for eCommerce websites.
Cons of Cloudflare:
- Possibility of man-in-the-middle forgery
- Unsolvable roadblocks can degrade performance
- Lowered usability due to unnecessary captchas
- Some advanced features like “log access,” are only available on expensive plans (Business and Enterprise).
Cloudflare is one of the most affordable ways to get a CDN for your site. It’s available in four plans: Free, Pro, Business, and Enterprise. The Pro plan is priced at $20 and the Business will cost you $200 per domain. The Enterprise plan is the “à la carte” type of offer which is priced and custom-tuned independently to meet the specific needs of the client.
Cloudflare offers specific add-ons, like Dedicated SSL Certificates, Load Balancing, Argo Smart Routing, and Rate Limiting, which require an additional fee on top of the monthly subscription.
Interestingly, even Cloudflare’s free plan comes with basic DDoS protection. There is also more advanced DDoS protection available on the premium plans. It’s no surprise that Cloudflare’s free, unmetered plan is a major draw for many businesses looking to dip their toes in CDN technology and speed up their site with minimal effort. The switch to a paid plan—or a different CDN provider altogether—is always possible later on.
Why choose Cloudflare?
Cloudflare has a few advantages speaking in its favor:
- It’s super affordable compared to the other CDN offerings and comes with a free tier.
- Cloudflare is a good choice if you don't have a lot of dynamic images or want transparent WAF (and other security features).
- Cloudflare has strong DDoS mitigation features (behind Akamai)
- Cloudflare offers managed security service with an unbeatable price point.
Cloudfront is an extended service of Amazon. The beta version of Cloudfront launched in November 2008, and then re-launched in January 2009 with more attractive pricing. Needless to say, Amazon operates a really impressive number of edge locations and boasts a global network of edge locations spread across different regions of the world.
CloudFront key features
Amazon Cloudfront offers easy integration with other popular AWS services like Amazon S3, Amazon EC2, AWS Lambda@Edge, AWS Elemental MediaStore and MediaPackage, Amazon CloudWatch, etc. which is probably the best part of using CloudFront. It also works with the AWS Management Console.
On top of that, CloudFront offers these additional features:
- Support for dynamic content, not just static assets.
- Reports on cache statistics and popular objects, monitoring and alarming, usage charts and more.
- Advanced security features and geo-restriction.
- 24/7 customer support (email and phone, although at an extra charge). By default, you just get access to a community forum.
Pros of CloudFront
- Per-usage billing model makes it really cost-effective
- Seamless integration with other AWS services
- A possibility to adjust the plan as you go depending on your current needs and pay only for the actual usage.
- Edge servers in many different continents including North America, South America, Asia, Europe, and Australia.
- CloudFront generates valuable insights via report charts that allow you to track trends in data transfer and requests for your website.
- Private content feature that lets you restrict access to your content.
Cons of CloudFront
- Dynamic content caching at only 16% rate, which is better than the average 6% seen across traditional CDNs, but is still far too low to deliver speedy eCommerce or other database-driven websites.
- Complex integration as compared to other CDNs
- Although CloudFront’s pricing follows the pay-per-use model, scalability may cost you a pretty penny. A website with low traffic can easily afford the service, but an increase in traffic will quickly translate into a heavier bill.
- Limited visibility into the underlying CloudFront structure.
- Technical support is there, but not free for all.
CloudFront is a pay-as-you-go CDN that helps you offer your end-user a seamless web experience by delivering them the content they requested via its nearest edge location. It offers three pricing tiers:
New AWS customers receive 50 GB data transfer out and 2,000,000 HTTP and HTTPS requests each month for one year. The free tier is metered per month. Usage is aggregated across all AWS edge locations, and automatically applied to your bill. Monthly usage does not roll over to the following period if not used.
One important caveat: you can only use the free plan for the first 12 months of becoming an AWS customer.
Unlike other CDNs on the market, CloudFront costs less where Amazon’s costs are lower. Their prices vary across geographic regions and are based on the edge location through which your content is served. Usage tiers for data transfer are measured separately for each geographic region, as seen below:
Discounted pricing is available for customers expecting at least 10 TB of data transfer per month—over a period of 12 months or longer. CloudFront discounts will vary based on the amount of the commitment.
Why choose CloudFront?
CloudFront is a great choice for you if you’re after a seamless integration with other AWS services or your existing AWS stack (i.e. automation and metrics) and need a CDN that supports fast delivery of highly dynamic content.
It is also a good choice if you have a lot of dynamically changing content, like eCommerce and Travel sites do, and want tight integration with your in place pipeline. CloudFront provides support for pushing content to your edge locations with higher TTLS, which basically means DDoS becomes Amazon's problem.
If you have a diverse audience base and you want to offer efficient video streaming CloudFront is also a great choice.
Layer0 key features
For a complete rundown of all the bells and whistles that come with Layer0 see the table below.
Layer0 comes in two tiers: Free and Enterprise. The former, although only a limited version of the full deal, is the easiest and fastest way to get started and experience the key advantages of Layer0.
Enterprise pricing depends on numerous factors, such as your traffic as well as the number of environments and seats you need. At this point, you will need to contact Layer0 directly to get a detailed cost estimate.
Why use Layer0?
Layer0 can be used by any website, but is primarily geared towards revenue-generating, database-driven sites, like eCommerce and Travel, which serve dynamic content to their users. On such sites, online shoppers typically wait for the JSON/HTML/SSR data which makes up the specific size, color, and price of specific products. This is what makes traditional CDNs inefficient for such websites, as they don’t cache such dynamic data.
Layer0 allows websites to achieve cache hit rates for dynamic data at the edge in the 95% range, while the sites that use traditional CDNs see a low 6%. For static content, the choice is simpler: CDNs can host the entire static contents of your site and distribute it without necessarily having to replicate databases to other regions.
Which CDN is the fastest?
Most CDN providers will try to wow you with various serious-sounding features, raw numbers and comparison sheets, but they simply cannot guarantee actual real-life speeds. In other words, your mileage may vary is something you hear when the speed improvement is not quite what you expected. Layer0 is one of few technologies out there that promises actual results—we guarantee sub-500ms median paint times (LCP) for eCommerce websites, regardless of the frontend or backend systems or eCommerce platforms used.
Try before you buy
When looking for a CDN, claimed speed is not always the most reliable distinguishing factor. Raw numbers never tell the full story—website performance is typically burdened with many variables beyond the platform’s control: time of day, size of your payload and the location of the internet user relative to the edge.
And because the results may vary depending on so many things, the easiest way to buy a CDN is to test-drive it on your website—just call the sales team and ask for a demo.
This assumption pretty much invalidates most comparison tables. When shopping for CDNs it’s easy to get lost in all these features and tech jargon. But the most important thing to remember is that, above all, you’re probably looking for performance, not a CDN for the sake of having one.