CDN services for lightweight JS widget

I have an extremely small javascript widget (about 50kb in size) that will reside in people’s websites. Hence I need just the CDN services to serve the widget to people around the world.

However, I am unsure as to which product plan to be using. Can someone point me towards the right direction?


Thank you for asking.

Unfortunately, you cannot host files at Cloudflare (yet), despite Cloudflare Images & Stream, until Cloudflare R2 Storage is available.

Until then, I’d suggest you to host your files on some public bucket.

You can try for example with BackBlaze B2 Storage or BunnyCDN or KeyCDN.
If using Backblaze B2 Storage, create account and a bucket, upload it there and connect your custom domain with your B2 bucket, therefore setup a Page Rule for caching at Cloudfalre for that particular resource.

Cloudflare acts as a Pull CDN, like most others, so when a file is requested for the first time, it is loaded in the cache. Subsequent requests will come from the cache until that item expires or is evicted for lack of use until the next request. You’re certainly welcome to use any other service that suits you best.

Helpful information for better understanding of how Cloudflare CND works can be read at the article from below:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.