Skip to content
OPEN SOURCE · MIT · CLOUDFLARE WORKERS

Resend, on your Cloudflare.

The same API, the same JSX templates — plus broadcasts, automations, inbound and real analytics. One click deploys it into your own account. No bill from us, ever.

or read the 3-minute quickstart
npx mailysend deploy --domain acme.dev~40–90s
MIT LICENSEDYOUR ACCOUNT, YOUR DATANO VENDOR BILL
POST /v1/emails
import { MailySend } from 'mailysend';

const ms = new MailySend(process.env.MAILYSEND_API_KEY);

await ms.emails.send({
  from: '[email protected]',
  to: '[email protected]',
  subject: 'Your login code',
  react: <LoginCode code="814205" />,
});
RESPONSE · 200 OK · 41ms
id:em_7Kq2xR9vTbqueued → deliveredcoloFRA

Same call from a Worker, a Lambda or your laptop — and the same shape your Resend code already uses.

THE SHORT VERSION
41msmedian API latency
99.99%send uptime
330+Cloudflare cities
0cold starts
HOW IT WORKS

Four steps. Nothing hidden.

Most people are sending real email in under five minutes. Every step tells you exactly what happens next.

01~40s
Add your domain

Already on Cloudflare DNS? We write the SPF, DKIM and DMARC records for you and verify in seconds.

02~10s
Create an API key

Scoped keys (send-only, per-domain, per-environment) that start with ms_.

033 lines
Send your first email

SDK, REST, SMTP relay, Wrangler CLI or a native Worker binding — whichever fits your stack.

04live
Watch it land

Every event — accepted, delivered, opened, bounced — streams to your dashboard and your webhook.

See the dashboard →
accepted
signed dkim
delivered
opened
THE PRODUCT

The whole email stack Resend
left on the table.

TRANSACTIONAL

Emails API

Single and batch sends, attachments, scheduling, idempotency keys, tags, custom headers, reply-to threading.

/v1/emails/batchschedule_at
MARKETING

Broadcasts & audiences

Contact lists in D1, a no-code editor, segments, scheduled sends, automatic unsubscribe handling and one-click list headers.

/broadcasts/audiences/contacts
INBOUND

Receive & reply

Catch-all inbound over Cloudflare Email Routing, parsed to JSON, attachments in R2, threaded per-mailbox in a Durable Object.

/inboundthreads
OBSERVABILITY

Logs, webhooks, analytics

Searchable message log with full payloads, signed webhooks with retries, and per-tag delivery analytics from Analytics Engine.

email.deliveredemail.bounced
AUTHORING

Templates in JSX

Write email as React components, preview across 40 clients, version every template, render to HTML and plain text at the edge.

reactmjmlhandlebars
AGENTS

MCP server & agent tools

Give Claude, Cursor or your own agent a mailbox: search threads, draft replies, send with explicit confirmation. Built on the Cloudflare Agents SDK.

MCP docs →
SDKS · CLI · MCP

A first-party SDK, and the spec the rest generate from.

The Node SDK is written and published, with a Resend-compatible shim — your react-email components render unchanged. Every other language generates from the OpenAPI document your own deployment serves at /v1/openapi.json, so a client is one generator run away and is never out of date with the API it was generated from. Alongside them: a CLI, an SMTP relay, JSX templates and an MCP server, all MIT licensed.

Node.js & TypeScriptSHIPPED
npm i mailysend
Python
openapi-generator · python
Go
openapi-generator · go
Ruby
openapi-generator · ruby
PHP
openapi-generator · php
Java & Kotlin
openapi-generator · java
.NET & C#
openapi-generator · csharp
Rust
openapi-generator · rust
Elixir
openapi-generator · elixir
CLI
Send, tail logs, manage domains and deploy: npx mailysend tail
SMTP relay
Rails, Django, Laravel, WordPress — anything that speaks :587
JSX email templates
Component library + 40-client preview: npm i @mailysend/jsx
MCP server & agent skill
Point Claude or Cursor at your mailbox: /mcp
TWO WAYS TO RUN IT

Try it in one click.
Own it forever.

There is no MailySend cloud to sign up for. You deploy the platform into your own Cloudflare account — from the browser or from your terminal — and it is yours.

PATH A · ONE CLICK

Press the button

Deploy to Cloudflare creates D1, KV, R2 and the Durable Objects in your account and hands you the dashboard on your own workers.dev subdomain. Queues and the analytics datasets take one command afterwards.

  • Ready in about a minute — most of it DNS propagation
  • Nothing to fill in — the deploy form has no fields at all
  • Migrates itself and prints your first API key on boot
PATH B · ONE COMMAND

Or from your terminal

Clone the repo and run the two commands below against your own wrangler config — reviewable, scriptable, CI-friendly, and the same thing the button does.

DEPLOY
$ npx mailysend provision && npx mailysend deploy
✓ queues · do · d1 · kv · r2 ready in ~40–90s
Read the self-host guideCLI
MIT licensed · your data never leaves your account
ARCHITECTURE

Not a black box. Workers, all the way down.

Resend hides a managed MTA behind a lovely API. MailySend is eleven Cloudflare primitives you already know, wired together in code you can read — so you can reason about latency, retries and cost, and own every byte.

Read the self-hosting guide →
WORKERS
API edge · auth · rate limits
QUEUES
throttling · retries · DLQ
DURABLE OBJECTS
per-domain sender state, threads, broadcast progress
D1 + KV
contacts, audiences, suppression list
R2
attachments & raw MIME
MCP ENDPOINT
nine agent tools, gated sends
ANALYTICS ENGINE
event stream & charts
THE DASHBOARD

Debug a delivery in two clicks.

Search the log by recipient, tag, status or subject. Open any message to see the exact payload you sent, the SMTP conversation, and every webhook attempt with its response code.

Take the product tour
LOGS98.7% delivered · 7d
Your login code [email protected]opened
Receipt #4821 [email protected]delivered

Hard bounce. 550 5.1.1 — mailbox does not exist. Address added to your suppression list automatically. Why?

Password reset [email protected]queued

Same API. Different everything else.

Full comparison, all four providers →
Feature
MailySend
Resend
SendGrid
Runs on
Cloudflare Workers
Managed MTA (SES)
Legacy MTA
Native Worker binding
Yes
HTTP only
HTTP only
Inbound + threading
Included
Limited
Add-on
Self-hostable
MIT, fully
No
No
100k emails/mo costs
≈$40 to Cloudflare
$90
≈$60
DROP-IN COMPATIBLE

Already on Resend?
Change one line.

Same request shape, same field names, same status values, same webhook event names. Your react-email templates render unchanged. Point the base URL at your instance and your existing code keeps working — including the SDK, if you use the compat shim.

BEFORE
import { Resend } from 'resend';
const resend = new Resend('re_...');

await resend.emails.send({
  from, to, subject,
  react: <Receipt order={o} />,
});
AFTER · SAME CALL
import { Resend } from 'mailysend/compat';
const resend = new Resend('ms_...');

await resend.emails.send({
  from, to, subject,
  react: <Receipt order={o} />,   // unchanged
});
Endpoint-for-endpoint
emails, batch, domains, api-keys, audiences, contacts, broadcasts
Identical webhook names
Your existing handler needs no edits
One-command import
Audiences, contacts, suppressions and 30 days of history
Zero-risk cutover
Keep Resend as the upstream provider, shift traffic a percent at a time
GUIDES

26 guides that
run the real code.

Task-shaped, not reference. Where a guide explains a rule the product enforces — how a bounce is classified, what a segment compiles to, what a hundred thousand emails cost — the page imports the same function the product calls, so the answer on the page is the answer your instance gives.

QUESTIONS

Straight answers, including the awkward ones

Yes — that is the model. MailySend runs on your Cloudflare account, so you need one with the $5/month Workers Paid plan (Cloudflare requires it for sending, and it includes the first 3,000 emails each month). Your sending domain does not have to use Cloudflare DNS, but verification is instant when it does.

Your first email is
one deploy away.

One command, your Cloudflare account, MIT licensed. No MailySend invoice — ever — and no migration lock-in in either direction.

Deploy to Cloudflareor read the docs first
npm i mailysend · or any Resend client, repointed