<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/legacy-image-provider-to-cloudflare-images-traffic-estimation-and-safe-rollout-gvq0ff3wg" -->

---
title: Legacy Image Provider to Cloudflare Images: Traffic...
description: Mercari&#x27;s Platform Network team shares how they migrated a legacy image transformation pipeline to Cloudflare Images while keeping existing URLs intact. Key...
canonical: https://daily.dev/posts/legacy-image-provider-to-cloudflare-images-traffic-estimation-and-safe-rollout-gvq0ff3wg
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Legacy Image Provider to Cloudflare Images: Traffic Estimation and Safe Rollout | daily.dev
og:description: Mercari&#x27;s Platform Network team shares how they migrated a legacy image transformation pipeline to Cloudflare Images while keeping existing URLs intact. Key...
og:url: https://daily.dev/posts/legacy-image-provider-to-cloudflare-images-traffic-estimation-and-safe-rollout-gvq0ff3wg
og:image: https://api.daily.dev/og/posts/GVq0FF3Wg.png
og:image:alt: Legacy Image Provider to Cloudflare Images: Traffic Estimation and Safe Rollout
og:image:width: 1200
og:image:height: 630
og:locale: en
---

[Mercari Engineering](https://daily.dev/sources/mercari)

[Read post](https://api.daily.dev/r/GVq0FF3Wg)

# [Legacy Image Provider to Cloudflare Images: Traffic Estimation and Safe Rollout](https://api.daily.dev/r/GVq0FF3Wg "Go to post")

Mercari's Platform Network team shares how they migrated a legacy image transformation pipeline to Cloudflare Images while keeping existing URLs intact. Key challenges included TLS/SSL issues with legacy S3 bucket naming conventions, egress cost estimation due to Cloudflare's different compression behavior (WebP files up to 50% larger), and zero-downtime rollout mechanics. They resolved S3 access via host-header-style routing with Terraform, validated image quality through pixel-level comparison and adjusted quality settings, estimated costs using 30-day APPROX\_COUNT\_DISTINCT queries on access logs, and rolled out traffic gradually using regex-based image ID matching (from 0.1% to 100%) with a three-phase cache rebuild strategy to avoid S3 rate limit overloads.

[#aws-s3](/tags/aws-s3 "Check all #aws-s3 posts")

Aug 06•10m read time•From [engineering.mercari.com](https://api.daily.dev/r/GVq0FF3Wg "engineering.mercari.com")

[![Post cover image](https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/79241a40201bd5b6ab5c3f6c12aad502?_a=AQAEuop)](https://api.daily.dev/r/GVq0FF3Wg "Go to post")

Table of contents

[Abstract](https://api.daily.dev/r/GVq0FF3Wg "Abstract")[What the migration looked like](https://api.daily.dev/r/GVq0FF3Wg "What the migration looked like")[Migration challenges](https://api.daily.dev/r/GVq0FF3Wg "Migration challenges")[How we resolved it: S3 access from Cloudflare](https://api.daily.dev/r/GVq0FF3Wg "How we resolved it: S3 access from Cloudflare")[How we resolved it: image quality, egress and cost](https://api.daily.dev/r/GVq0FF3Wg "How we resolved it: image quality, egress and cost")[How we resolved it: zero-downtime rollout details](https://api.daily.dev/r/GVq0FF3Wg "How we resolved it: zero-downtime rollout details")[Conclusion](https://api.daily.dev/r/GVq0FF3Wg "Conclusion")

165 Impressions

Comment

Bookmark

Copy

![Placeholder image for anonymous user](https://media.daily.dev/image/upload/s--qsFuKGv_--/t_logo,f_auto/public/noProfile)Share your thoughtsPost

[![Mercari Engineering's image](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/cdde515cd83640748689d74c2d938fcf)](https://daily.dev/sources/mercari)

[Mercari Engineering](https://daily.dev/sources/mercari "https://daily.dev/sources/mercari")

Mercari's platform is a resource for developers and technology enthusiasts, offering insights into e... Read more

32 Followers

•

371 Upvotes

#### Would you recommend this post?

Copy link

WhatsApp

Facebook

X

New Squad

Copy linkShare with your friends

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Legacy Image Provider to Cloudflare Images: Traffic Estimation and Safe Rollout","url":"https://daily.dev/posts/legacy-image-provider-to-cloudflare-images-traffic-estimation-and-safe-rollout-gvq0ff3wg","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/legacy-image-provider-to-cloudflare-images-traffic-estimation-and-safe-rollout-gvq0ff3wg"},"datePublished":"2026-08-06T00:15:51.509Z","dateModified":"2026-08-06T03:01:14.399Z","description":"Mercari's Platform Network team shares how they migrated a legacy image transformation pipeline to Cloudflare Images while keeping existing URLs intact. Key...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/79241a40201bd5b6ab5c3f6c12aad502?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/79241a40201bd5b6ab5c3f6c12aad502?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Mercari Engineering","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Mercari Engineering","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/cdde515cd83640748689d74c2d938fcf","url":"https://daily.dev/sources/mercari"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/legacy-image-provider-to-cloudflare-images-traffic-estimation-and-safe-rollout-gvq0ff3wg","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"aws-s3","timeRequired":"PT10M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Mercari Engineering","item":"https://daily.dev/sources/mercari"},{"@type":"ListItem","position":3,"name":"Legacy Image Provider to Cloudflare Images: Traffic Estimation and Safe Rollout"}]}
```

