Skip to content

Transactional Email API for Apps and AI Agents

Mailfully is the best-priced transactional email API, with the most generous free plan of any provider: 5,000 emails a month, free forever.

5,000 emails a month free, then plans from $19/mo with a flat $0.40 per 1,000 emails.

send.tsts
import { Mailfully } from "@mailfully/node";

const mailfully = new Mailfully({
  apiKey: process.env.MAILFULLY_API_KEY,
});

const { data } = await mailfully.emails.send({
  from: "you@yourdomain.com",
  to: "customer@example.com",
  subject: "Welcome aboard",
  html: "<p>Thanks for signing up!</p>",
});

Reliable, Secure Transactional Email API for Your Platform

A simple, secure API with custom domains, templates, webhooks, suppressions, and per-message logs.

Simple API

One authenticated POST sends an email. A typed REST API under /v1, snake_case on the wire, with a single error envelope. The official @mailfully/node SDK returns a data-or-error result and never throws.

POST /v1/emails{ from, to, subject, html }
202 { "id": … }

Debug logs

Every message keeps its full event timeline (accepted, message id, delivery, bounce, complaint) down to the raw SMTP conversation.

Templates

Reusable email templates with variable placeholders, managed through the API and dashboard. Change an email's copy without editing code.

Secure

Scoped API keys authenticate every request. We store only a hash, never your secret. Tenant data is isolated by construction and encrypted in transit and at rest.

Custom domain

Verify your own sending domain with guided DKIM, SPF, and DMARC records, then send as you@yourdomain.com with authentication aligned before your first message goes out.

Webhooks

Delivery, bounce, and complaint events arrive as signed, retried webhooks, with a per-endpoint circuit breaker and replay.

Suppressions

Hard bounces and complaints are suppressed automatically and stay out of future sends. Inspect, add, and remove entries anytime.

Detailed Web Dashboard to Configure and Track

Bounce and complaint rates are measured against the same thresholds that get an account throttled or suspended, so trouble arrives as a warning at 2% rather than a suspension at 10%. Break any figure down by recipient domain or tag, and the per-message log behind it is one click away.

The Mailfully analytics screen. A banner reads deliverability is at risk. Bounce rate is 2.90% in the watch band, complaint rate 0.72% past the critical threshold, and Gmail spam rate has no data yet. Below are reputation over time, headline rates with sparklines, thirty days of send volume split into delivered, complained and bounced, and a per-domain breakdown table.

One Line to Install

The official SDK is a typed wrapper over fetch on Node 24+ with zero dependencies of its own, and every call returns a data-or-error result, so failures are values you handle rather than exceptions that crash a background job. Skip the SDK entirely if you prefer: the REST API and the SMTP relay need nothing installed at all.

terminalbash
npm install @mailfully/node
# or: pnpm add @mailfully/node
#     yarn add @mailfully/node

REST API + SMTP relay

Send over HTTPS or drop-in SMTP. Same delivery, logging, and suppression underneath either path.

Proven delivery foundation

Sending infrastructure with years of deliverability history underneath, and the operational layer (logs, billing, suppression, abuse handling) built on top.

Templates Let You Change an Email Without Editing Code

Store the markup once, then send it by id with the variables filled in. Placeholders are plain {{ product }} , so there is no template language to learn, and values are HTML-escaped on the way in. Edit the body in the dashboard or over the API; the send call never changes.

order-confirmed.tsts
// The template owns the markup.
await mailfully.emails.send({
  from: "orders@yourdomain.com",
  to: "customer@example.com",
  subject: "Your order is confirmed",
  template: {
    id: "tmpl_01JQ8ZC3S8W0V6M4T2Y7N9RXKD",
    variables: {
      product: "Vintage Macintosh",
      price: "$499.00",
    },
  },
});

Comprehensive Webhooks for All Event Types

Eight event types (delivered, bounced, complained, failed, delayed, opened, clicked, suppressed) arrive as one JSON envelope, signed with Svix-compatible webhook-signature headers you can verify with an off-the-shelf library. Delivery is at-least-once behind a per-endpoint circuit breaker, so dedupe on webhook-id and answer with any 2xx.

app/api/webhooks/mailfully/route.tsts
import type {
  MailfullyEventType,
} from "@mailfully/node";

export async function POST(req: Request) {
  const event = (await req.json()) as {
    type: MailfullyEventType;
    data: { email_id: string; to: string[] };
  };

  if (event.type === "email.bounced") {
    await deactivateAddress(event.data.to);
  }

  // Any 2xx acks it.
  return new Response(null, { status: 204 });
}

Test Keys Let You Test Everything Without Changing Any Code

Swap mf_live_ for mf_test_ and the same code runs the same path (same API, same delivery pipeline, same webhooks) into the mailbox simulator instead of a real inbox. Address a message to bounce@example.com and the bounce event fires for you to build against. Test sends never touch your reputation or quota, and are never metered.

.envbash
# Development — the real send path, into the mailbox simulator.
MAILFULLY_API_KEY=mf_test_xxxxxxxxxxxxxxxx

# Production
MAILFULLY_API_KEY=mf_live_xxxxxxxxxxxxxxxx

Fast to Get Started and Flexible to Build On

I spent years wrestling with SendGrid's legacy API and archaic template builders. Moving our transactional stack to Mailfully felt like stepping into the future—the API is incredibly intuitive, and templates as React components finally brought sanity to our release process.
SarahSenior Backend Engineer
Honestly, the best feature of Mailfully isn't even the sending itself; it's the audit log. Being able to inspect the exact payload, headers, and delivery status of every single email in a clean, searchable UI has saved us hours of debugging time that we used to lose digging through raw provider logs.
MarcusLead DevOps Architect
I'm usually skeptical of 'developer experience' marketing, but the CLI integration is genuinely top-tier. I set up our domains, verified our DNS records, and triggered our first test email entirely from the terminal. It's rare to find an email service that treats the developer as the primary user rather than an afterthought.
AbhisheckFull-Stack Developer

Start Free. Scale with Best in Class Pricing

5,000 emails a month free, then plans from $19/mo with a flat $0.40 per 1,000 emails.

Start free