Offloading image requests to Cloudflare Images Domain

Here’s my current use case:
I have numerous images currently hosted on a website and would like to serve proxied versions of them through Cloudflare Images in order to prevent them from sending ANY requests to my origin server. Is there a way to bulk migrate existing images to Cloudflare Images while preserving their paths? Also is there a way to automatically add new images uploaded into a Wordpress instance to Cloudflare Images?

You can use Cloudflare cache reserve or workers + KV storage it will cache your images for life time.

You can use bunny CDN Perma cache + Cloudflare CDN for cheap price cost only 0.01 per GB.

The issue I’m trying to solve for is that my host (Kinsta) charges based on visits, and I have images that get served across my domains which are resulting in multiple visits being triggered on single visits. So I need a solution where I can serve images under a different domain that is under Cloudflare rather than my own domain.

I was hoping I could use Cloudflare Images to do this but it sounds like I would need to create something that loaded all of my existing images into Cloudflare, and then mapped the old URLs to the Cloudflare URLs.

Ideally, there would be a solution where I could call a URL like:


And that would act as a proxy for that request and fetch this image:

If the image is already in the CDN cache, don’t refetch it unless it has expired.

You can use Cloudflare workers as a proxy and store your images on kV or R2.

If U asked for Cloudflare image which is $5 u can try this plugin Offload, Store, Resize & Optimize with Cloudflare Images – WordPress plugin |

or find at github for script

This topic was automatically closed after 11 days. New replies are no longer allowed.