Open source · MIT
Run Squadmail on your own Cloudflare account
The same code that powers our cloud — one Worker, deployed with one click. You keep full control over your data, domains and limits.
Cloud or self-hosted?
| Squadmail Cloud | Self-hosted | |
|---|---|---|
| Price | From $1/month | Free software + your Cloudflare & AWS usage |
| Setup | Sign up and go | One-click deploy + Amazon SES |
| Your own domain | ||
| All features (MCP, API, labels, webhooks) | ||
| Updates, backups & monitoring | Done for you | You |
| Support | Email support, priority on Team+ | Community (GitHub) |
| Data location | Cloudflare global network | Your Cloudflare & AWS accounts |
| Limits | Per plan | You decide |
Don’t want to run infrastructure? Start in the cloud from $1/month instead.
Under the hood
From SMTP to your agent in milliseconds — entirely on Cloudflare.
- 01
Receive
Amazon SES accepts mail for your domain and notifies the Worker via signed SNS.
- 02
Policy
Sender rules, TTL, flood protection. Rejections are logged, never silent.
- 03
Parse
MIME → text, sanitized HTML, attachments. OTPs and magic links extracted.
- 04
Store
D1 for metadata, R2 for raw mail & files. Marked ready only when complete.
- 05
Label
Regex rules, then one Clef call for your yes/no labels and spam score.
- 06
Deliver
Live dashboard, wait/SSE/MCP for agents, signed webhooks with retries.
Developer first
One API. Three ways to talk to it.
A typed REST API with OpenAPI 3.1, long-polling /wait and
SSE streams — or let your agent drive it through MCP. Same scopes, same limits, same audit trail.
- ✦ Readable random addresses: swift-otter-4821@…
- ✦ OTP codes & magic links extracted server-side
- ✦ Emails only appear once attachments are stored
# 1. a disposable inbox for your test run
curl -s https://app.squadmail.dev/api/v1/inboxes \
-H "Authorization: Bearer $SQUADMAIL_KEY" \
-d '{"ttl_minutes": 30, "agent_name": "e2e"}'
# 2. block until the verification mail lands
curl -s "https://app.squadmail.dev/api/v1/inboxes/$INBOX/wait?timeout=60" \
-H "Authorization: Bearer $SQUADMAIL_KEY" | jq .extracted.code
# "482913"Self-host in one click
Your domain. Your account. Two minutes.
The Deploy button forks the repo, provisions everything below on your Cloudflare account and runs the migrations. Add your AWS keys and the setup wizard connects Amazon SES with one click, shows the DNS records for your domain and waits live for your first mail.
Worker
SvelteKit app, API, MCP, mail webhook
D1
inboxes, emails, labels, users
R2
raw MIME & attachments
Durable Objects
realtime hub & rate limits
Queues
labeling & webhook delivery
Workers AI
Clef decision models
KV
OAuth grants for MCP
Amazon SES
receiving & sending (your AWS)
Self-hosting questions
What does self-hosting cost?+
Squadmail itself is free. You pay Cloudflare for what you use — for most teams that is the $5/month Workers Paid plan, plus optional sending ($0.35 per 1,000 emails after 3,000 free) and optional AI labels.
Is the self-hosted version limited?+
No. It is the same code that runs our cloud. You configure limits and features yourself with environment variables.
Who maintains my instance?+
You do. Pull updates from GitHub and Workers Builds redeploys automatically. If you’d rather not, our cloud plans include updates, backups and support.
Can I move between cloud and self-hosted?+
Yes. Both use the same data model and API, so your agents and tests keep working — just change the base URL.