Know the exact repository and deployment ceilings early
Small business websites rarely approach 20,000 HTML pages, yet a single uncompressed promotional MP4 or 40 MB catalog PDF immediately breaks Cloudflare Pages deployments.
- GitHub hard per-file block: 100 MB.
- Cloudflare Pages single asset ceiling: 25 MiB.
- Cloudflare Pages deployment file ceiling: 20,000 files.
Compress site imagery first, offload bulk downloads second
Convert inline hero photography to crisp WebP under 250 KB directly inside public/images/, and upload genuinely multi-megabyte assets to R2 buckets mapped cleanly to downloads.yourdomain.com.
Set proper Content-Disposition headers for direct downloads
Configure file metadata in R2 cleanly so clicking a brochure or ZIP downloads reliably with clean filenames instead of opening garbled browser text tabs.
Common questions
Should I use Git LFS for large website PDFs?
Usually no—uploading directly to R2 on a custom subdomain avoids Git LFS quota complexity while delivering assets directly over Cloudflare's edge network.
How much free R2 storage is included to start?
Check Cloudflare's live R2 pricing page for current free monthly storage/operations allowances—standard informational PDFs and press packs typically cost pennies or $0.
References
Provider interfaces and limits can change. Consult the original documentation before changing production settings.