CDN Setup Guide
Set up a content delivery network to serve your content from edge locations worldwide. Reduce latency, offload origin traffic, and improve the user experience for global audiences.
Usage
Ask about choosing a CDN provider, configuring cache rules, or optimizing your CDN setup for your content type.
Examples
- "How do I set up Cloudflare as a CDN for my application?"
- "What cache headers should I set for different content types?"
- "How do I purge CDN cache after a deployment?"
Guidelines
- Set long cache durations for static assets with content-hash filenames
- Use short or no cache for dynamic content and HTML pages
- Configure cache purge in your deployment pipeline for immediate updates
- Set up custom error pages at the CDN level for a better user experience
- Monitor CDN cache hit ratios to ensure effective caching