Learn how to send your first email using Next.js and the Resend Node.js SDK.
To get the most out of this guide, you’ll need to:
Prefer watching a video? Check out our video walkthrough below.
Get the Resend Node.js SDK.
Start by creating your email template on components/email-template.tsx
.
Create an API file under pages/api/send.ts
if you’re using the Pages Router or create a route file under app/api/send/route.ts
if you’re using the App Router.
Import the React email template and send an email using the react
parameter.
See the full source code.
See the full source code.
Learn how to send your first email using Next.js and the Resend Node.js SDK.
To get the most out of this guide, you’ll need to:
Prefer watching a video? Check out our video walkthrough below.
Get the Resend Node.js SDK.
Start by creating your email template on components/email-template.tsx
.
Create an API file under pages/api/send.ts
if you’re using the Pages Router or create a route file under app/api/send/route.ts
if you’re using the App Router.
Import the React email template and send an email using the react
parameter.
See the full source code.
See the full source code.