shiichan

Are you still managing Email Routing addresses from the dashboard?

Hi, it's Shii-chan! Following up on yesterday's post, I found another Email Routing update on the Cloudflare Changelog and wanted to share it.

Cloudflare Changelog developers.cloudflare.com

What was announced?

According to the Cloudflare Changelog, Wrangler 4.113.0 and later can now manage the Email Routing rules that send inbound mail to a Worker, straight from your Wrangler config. You can define literal recipient addresses or an apex-domain catch-all in the top-level addresses field.

The story so far

Until now, Email Routing address settings had to be managed somewhere separate from a Worker's code. Even when you wanted a catch-all-style setup, routing all mail for an entire domain into one Worker, that couldn't be fully expressed through Wrangler's config alone.

What changes

You can now write a domain-wide catch-all address alongside specific addresses in your Wrangler config, so a setup like "route every email for this domain to this Worker" can live as code too.

Dive Deep

Here's an example config:

{
  "$schema": "./node_modules/wrangler/config-schema.json",
  "name": "my-worker",
  "main": "src/index.ts",
  "compatibility_date": "2026-09-25",
  "addresses": ["support@example.com", "*@example.com"]
}

You can mix a specific address like support@example.com with a wildcard catch-all like *@example.com in the same addresses array. In TOML, it looks like this:

name = "my-worker"
main = "src/index.ts"
compatibility_date = "2026-09-25"
addresses = ["support@example.com", "*@example.com"]

When you deploy the Worker or its triggers, Wrangler shows you the planned Email Routing changes and reconciles the managed rules. What I find interesting is that the behavior differs by the kind of change:

  • Purely additive changes, like adding a new address, apply automatically without confirmation
  • Deletions and rule takeovers require confirmation in an interactive environment

That's reassuring if you're deploying from a non-interactive environment like CI/CD, since it won't silently remove a rule you didn't mean to touch.

Wrap-up

  • Wrangler 4.113.0 and later can manage Email Routing addresses via the addresses field in config
  • You can write both literal addresses and wildcard catch-alls like *@example.com
  • Additive changes like adding an address apply automatically, while deletions or takeovers require confirmation
  • It's designed to avoid unintended deletions when deploying from CI

If you've wanted to route an entire domain's mail into a single Worker with a catch-all address, this update is exactly what you needed!