I am being handed off a static site that serves a modest amount of audio files – these are .m4a, roughly 1-6 MB in size, ~60 files currently. The number may grow, but not substantially. I am assessing Cloudflare Pages as a platform for serving this site and its media files.
I am concerned with bandwidth expense if traffic to these files suddenly spikes. Is this something I need to worry about? Does Cloudflare Pages offer anything in terms of rate limiting, DDoS protection, or a spend limit that would shut off traffic that could help me here?
It’s my understanding that each Pages asset get cached on the Cloudflare CDN. Is it acceptable to serve these files on Cloudflare Pages, or does Cloudflare expect me to serve them on R2 instead?
From poking around it seems like the Cloudflare Self-Serve Subscription Agreement used to include the clause below as Section 2.8, but it has been removed.
“Use of the Services for serving video or a disproportionate percentage of pictures, audio files, or other non-HTML content is prohibited, unless purchased separately as part of a Paid Service or expressly allowed under our Supplemental Terms for a specific Service”
Here are a couple older relevant threads I’ve referenced but they don’t quite answer my question:
As for what is “disproportionate”, no one knows, as Cloudflare doesn’t want to say.
My take:
R2 includes 10 million reads per month. As long as you stay below that (and assuming you are on a paid worker plan), I’d just go with keeping the files in Pages. I don’t think Cloudflare has any interest in forcing you to add complexity to your app if it makes exactly 0$ difference in your bill.