Skip to content

Image Optimization Setup

Overview

We use Cloudflare Image Transformations to serve compressed and optimized images through Cloudflare CDN.

Original images are currently hosted on Backblaze. A Cloudflare Worker rewrites/processes source image URLs and returns a Cloudflare Image Transformation URL on the fly.

Current Setup

  1. Client requests an image URL.
  2. image-optimizer Worker receives the request.
  3. Worker maps the original Backblaze-hosted image URL to a Cloudflare Image Transformation URL.
  4. Cloudflare applies the configured transformation (resize/compress/format optimization) and serves via CDN.

References

Pricing

Cloudflare Images Free plan includes up to 5,000 unique transformations per month.

Reference: Cloudflare Images Pricing