Skip to content
supastack
Browse documentation
WebNext.js

For AI agents: fetch the complete documentation index at /llms.txt, the full documentation corpus at /llms-full.txt, the agent skill at /skill.md, or this page as Markdown at /docs/web/resend-email.md (or send Accept: text/markdown).

Add Resend email

Create a free Resend account, verify a sending domain, and switch EMAIL_PROVIDER so codes and receipts reach real inboxes.

Beginner walkthrough

Prerequisites: the app running locally (Ship in 5 minutes). Start free — no card, and Resend's free tier covers development volumes.

Quick terms: EMAIL_PROVIDER=local is the default — messages are written to the built-in /mail-preview page and never leave your machine, which is perfect while building. Resend is the adapter that delivers to real inboxes. EMAIL_FROM is the sender identity templates use; its address must sit on a domain Resend has verified. DNS records are the lines you paste at your registrar or Cloudflare so receiving mailboxes trust your sender.

What you create: a Resend account, a verified sending domain, and one API key — the domain step is the only waiting part, since DNS propagation runs from minutes to hours.

Create the Resend account

1. Open resend.com → Sign up, confirm your email, and you land on the dashboard.

2. Start with the free tier — you can even send test mail from Resend's shared sender before owning a domain, which the next section covers.

Verify your sending domain

Quick try, no domain: the address [email protected] works as EMAIL_FROM immediately — but it only delivers to the email you signed up with, never to users. Use it to see the pipeline work, then do the real setup.

1. Open Domains → Add Domain and enter the domain you send from (for example yourdomain.com; a subdomain such as mail.yourdomain.com also works and keeps records tidy).

2. Resend lists the DNS records to create — DKIM TXT records plus MX/SPF or CNAME entries depending on account age. Add each one at your DNS host: your registrar's DNS page, or Cloudflare if you moved nameservers. On Cloudflare keep the proxy cloud grey (DNS only) for mail records — proxied records never verify.

3. Back in Resend click Verify. Expected: the domain flips to Verified. Propagation varies from minutes to a day; the domain page names the exact record that still fails to resolve.

Once verified, any address on the domain works as a sender — hello@, no-reply@, whatever EMAIL_FROM uses — no per-address registration needed.

Create the API key

1. Open API Keys → Create API Key.

2. Permission: Sending access is enough — the kit only sends. Name the key for its environment (production, local) so a leaked dev key can be revoked without touching production.

3. Copy the re_… key now — it is shown once. Losing it just means creating another.

Add the values to the app

Set the lines below in apps/web/.env.local. RESEND_API_KEY is server-only — never NEXT_PUBLIC_/EXPO_PUBLIC_, never committed; EMAIL_PROVIDER and EMAIL_FROM are plain configuration. Restart the dev server after editing.

EMAIL_FROM must sit on the verified domain: [email protected] only reaches your own signup address, and an unverified domain gets a 403 rejection from Resend.

# apps/web/.env.local
EMAIL_PROVIDER=resend
EMAIL_FROM="Your Product <[email protected]>"
RESEND_API_KEY=re_…

Verify and troubleshoot

Restart, open /auth, and request a sign-in code to a real inbox you control. Expected: the message arrives, and Resend → Emails shows the delivery with a green status — that log is also where bounce and error reasons live.

Nothing sent? Check EMAIL_PROVIDER=resend actually saved in apps/web/.env.local and restart. A 403 in the server log means EMAIL_FROM is not on the verified domain — or [email protected] was sent to someone other than yourself.

Different provider later? EMAIL_PROVIDER also accepts ses (with the AWS keys) and the postmark, sendgrid, mailgun, smtp, brevo transports — same EMAIL_FROM contract, different env names, all listed in .env.example. The email guide compares them.

If you want to continue setup, read Set up Amazon SES email.

Frequently asked questions

14 questions

What is supastack?

supastack is a modular foundation for building AI-powered SaaS products. It brings together common infrastructure so you can focus on product-specific features.

Does it support web and mobile?

Yes. supastack includes Next.js and Expo apps as starting points for web and mobile experiences.

What authentication is included?

Better Auth covers email OTP, magic-link, and social sign-in; email/password stays available at the API layer and through the Auth.js credentials engine for products that need it. Personal workspaces are provisioned with the account so product records stay scoped from day one.

How does it support AI?

supastack includes configurable multi-provider AI, usage tracking, budgets, and encrypted bring-your-own-key support.

How are subscriptions handled?

For products built on the kit, Stripe billing, subscriptions, and entitlements form the paid-access foundation. Provider secrets stay server-only.

Where does my product-specific code live?

Product-specific features remain in a separate codebase while the product configures and integrates supastack’s foundation modules.

How does supastack pricing work?

The kit is a one-time purchase with lifetime updates: One Platform at $249 (temporary launch price, $100 off the regular $349) — your pick of Next.js (Web), Expo (iOS & Android), or Tauri (macOS & Windows Desktop) — or the All Platforms Bundle at $499 (temporary launch price, $100 off the regular $599) with every platform and the full monorepo, plus $75 per extra developer seat. No kit subscription. Checkout on this site delivers your license key by email, with repository access via GitHub invite.

How do workspaces scope my data?

User-owned records are scoped by workspaceId. Identity, entitlements, AI usage, billing events, and audit entries stay inside the personal workspace boundary.

How do background jobs work?

Trigger.dev is the explicit job runtime. The JobRunner contract only promises enqueue, status, and cancel—workflow semantics stay Trigger.dev-specific and explicit.

How is email different from outreach?

Transactional email covers product workflows such as completion notices. Cold outreach and campaigns are product concerns outside this kit’s email module.

How do mobile purchases work?

Mobile includes native purchases and restore through RevenueCat, with access verified by your server. Configure the store accounts and complete device testing before release. Web billing remains separate.

Where do AI provider keys live?

Bring-your-own-key credentials are encrypted and stay server-only. Keys are redacted from logs; usage and budgets remain visible at the workspace level.

Which payment methods does checkout accept?

The Stripe-hosted checkout accepts cards and can also offer Alipay and WeChat Pay once those wallets are enabled on the Stripe account — handy for buyers in China. Wallet authorizations confirm asynchronously, so the license page updates as soon as the payment clears.

Can I get a refund?

After you've got access to the repository, supastack is yours forever, so it cannot be refunded. But rest assured, you get the complete source code with lifetime updates to build and ship unlimited products for yourself or clients. You just cannot resell the code or redistribute the repository as a starter kit or template.

EN
Theme