Sending From Aliases
Reply to mail and write new messages from an aliasA stand-in address; mail still lands in your real inbox, so the other side never learns your real address.
Why Use This Feature?
- Keeps your real address private in both directions, not only for the mail you receive.
- Lets you press Reply in your usual mail app, with no copying of addresses.
- Starts new conversations from an alias by writing to one address on your own domain.
- Keeps the same switches as receiving, so a disabled or expired alias can't send either.
Requirements
- The setting —
send_from_aliasesset totrueinsettings, or Send and reply from aliases? answered yes in the interactive Settings menu. - Workers Paid — Replies go to addresses outside your account, which Cloudflare Email Sending only allows on the Workers Paid plan (Cloudflare docs). Deploy onboards your base domainThe domain every alias lives on to Email Sending and adds its DNS records, so the upgrade is the only step left to you.
- Three more token permissions —
Zone > Email Sending > Edit,Zone > DNS > Edit, andAccount > Billing > Read, which deploy checks for before it changes anything, as Deployment lists. Billing is read-only and lets deploy see which Workers plan the account is on. - A mail provider that passes DMARC — The WorkerMailmask itself, running on your Cloudflare account only sends mail that passed DMARC for your destinationYour real inbox, where an alias's mail ends up address, which large providers such as Gmail and Fastmail do.
Usage
{
"settings": {
"worker_name": "mailmask",
"base_domain": "example.com",
"subaddressing": true,
"add_alias_headers": true,
"send_from_aliases": true
}
}
Run mm deploy after turning it on. Deploy sets up everything sending needs:
- Email Sending — Onboards the base domain to Cloudflare Email Sending, unless it already is.
- DNS records — Adds the
cf-bounceMX, SPF, and DKIM records, and a DMARC record when the domain has none, skipping any that already exist. - Subaddressing — Turns on Email Routing subaddressing so reply addresses reach the alias.
- Binding — Gives the
MAILMASK_EMAILsend_emailbinding no recipient allowlist, so replies can reach anyone.
Running deploy again changes nothing that is already in place. After the setup, deploy runs two checks:
- Records resolve — Cloudflare's API has no "verified" state for a sending domain, so deploy looks each Email Sending record up on public DNS through Cloudflare's resolver (1.1.1.1), for up to a minute. Any record that doesn't resolve yet is named in a "pending" warning; deploy again later to check it.
- Workers plan — Deploy reads the account's subscriptions. It warns about Workers Paid only when the account is on Workers Free, or when the plan can't be read, and the warning says which.
Every deploy also reminds you that Reply All exposes your real address.
info
New DNS records usually work within 5 to 15 minutes on Cloudflare DNS, and can take up to 24 hours (Cloudflare docs), so a "pending" warning right after the first deploy is normal.
Replying
With the setting on, mail to [email protected] from [email protected] arrives from [email protected], the alias's reply addressOne sender's own address under an alias for that sender. Your mail app shows the sender's real address as the name, and Reply goes to the reply address.
The Worker then sends your reply from [email protected] to [email protected]. The subject, date, content, attachments, and threading headers go along, and every other header, including your name, mail client, and real address, is left out.
warning
Use Reply, not Reply All. Other recipients of the original message, and the alias itself, are not reply addresses, so Reply All would mail them straight from your real inbox.
Writing a New Message
To write to someone from an aliasA stand-in address; mail still lands in your real inbox, send mail from the alias's destination to the alias, a +, their address with = in place of @, and your domain:
To write to [email protected]
from the alias [email protected]
send mail to [email protected]
Mail from anyone other than the alias's own destination address to a reply address is treated as ordinary mail to the alias, so nobody else can send as your alias.
Limits
- Workers Free — Cloudflare Email Sending to outside addresses is not part of the free plan, so a reply bounces back to you with the Cloudflare error until you upgrade. Forwarding still works, because sends to your own verified destination are free on every plan (Cloudflare docs).
- Monthly quota — Workers Paid includes 3,000 outbound emails a month, then charges per 1,000, and sends to your verified destinations don't count toward it (Cloudflare docs).
- Daily quota and size — New accounts start with a daily sending quota that grows over time, and each message can be up to 25 MiB (Cloudflare docs).
- Long addresses — The part before the
@of a reply address can be at most 64 characters. When the alias and the sender's address are too long together, the message is forwarded the plain way, and a reply to it would come from your real address. - Lowercase — Reply addresses are lowercase, so a sender whose mailbox name depends on capital letters may not get your reply.
- One recipient — A reply goes only to the sender its reply address stands for, even if you add more people in
ToorCc. - Your message as written — The body is sent unchanged, so quoted text and your signature go along as you wrote them.
How It Works
- A forwarded message is rebuilt with
FromandReply-Toset to the reply address, then sent to your destination through thesend_emailbinding. If that send fails, the Worker forwards the original the plain way instead. - Mail to a reply address reaches the alias's routing rule, because Email Routing subaddressing matches
alias+anything@. - The Worker checks that the
Fromaddress is the alias's destination and that Cloudflare's firstAuthentication-Resultsheader showsdmarc=pass. Mail that fails is rejected withSender could not be verified. - It checks that the alias is enabled and not expired, rebuilds the headers, and sends the message from the alias to the sender.
Mail is handled in memory and never stored, the same as forwarding.