Our community deploys Astro sites just about everywhere. Whether you're on a Node server, a serverless function, or even a Cloudflare worker, I love how Resend just works.
Ben Holmes
Senior Web Developer at Astro, Astro Core Team Member
Resend seamlessly integrates into any Astro site via the Node SDK or API endpoints. Add an SSR adapter and send emails, create contacts, and more safely from the server in any deployment environment Astro supports.
import type { APIRoute } from "astro";import { Resend } from 'resend';const resend = new Resend(import.meta.env.RESEND_API_KEY);export const POST: APIRoute = async ({ request }) => {const { email } = await request.json();const { data, error } = await resend.emails.send({from: 'Acme <onboarding@resend.dev>',to: [email],subject: 'Hello world',html: '<strong>It works!</strong>',});return new Response(JSON.stringify(data));}
Learn how to send reliable, production-ready emails in your Astro site.
import { defineAction } from 'astro:actions';import { z } from 'astro:schema';import { Resend } from 'resend';const resend = new Resend(import.meta.env.RESEND_API_KEY);export const server = {send: defineAction({accept: 'form',input: z.object({email: z.email(),}),handler: async ({ email }) => {const { data, error } = await resend.emails.send({from: 'Acme <onboarding@resend.dev>',to: [email],subject: 'Hello world',html: '<strong>It works!</strong>',});return data;},}),};
Integrate Resend with Astro Actions for sending email with type-safe backend functions. Handle form submissions with web defaults in SSR and progressively add client-side JavaScript for a better user experience.
Astro's React adapter is a perfect match for react.email, our collection of high-quality, unstyled components for creating beautiful emails using TypeScript. Forget about inconsistencies with different email clients.
import { Html, Button } from 'react-email';import * as React from 'react';interface EmailProps {link: string;}export const Email: React.FC = ({link,}) => (<Html lang="en" dir="ltr"><Button href={link} style={{ color: '#61dafb' }}>Click me</Button></Html>);
Resources to help you integrate email into your application quickly.
Follow the step-by-step guide and learn how to send your first email using Astro.
Understand the REST API endpoints and each of the parameters that can be used.
"Our team loves Resend. It makes email sending so easy and reliable. After we switched to Dedicated IPs, our deliverability improved tremendously and we don't hear complaints about emails landing on spam anymore."Vlad MatsiiakoCo-founder of Infisical
"As a developer I love the approach that the Resend team is taking. Its so refreshing. They are also extremely user-centric and helpful in terms of getting you up and running, sending beautiful emails that deliver."Hahnbee LeeCo-Founder at Mintlify
"We value tools that feel stable, well thought out, and aligned with the standards we expect across our stack. Resend meets those expectations. It lets our team stay focused on building the larger platform rather than getting pulled into the overhead that typically comes with legacy email infrastructure."Bradley GreenwoodVP of Engineering at MrBeast
"Our partnership with Resend has been a great experience. They've made sure we can focus on what we do best—building our product and growing our business."Sahil LavingiaCEO of Gumroad
"Switching over to Resend from SendGrid marked a significant improvement in our email management. We started with a small test - waitlist emails for our iOS and Windows apps. Within 30 minutes, we were done."Thomas MannFounder & CEO of Raycast
"The simplicity and reliability of Resend allowed our engineers to focus on building features rather than troubleshooting email infrastructure."Amadeo PellicceConnectors, Agents and Automations Lead at Replit
"We're a small team with a lot on our plates. Email infrastructure is something we don't want to think about, and with Resend we don't have to."Peter SuhmOps at Tailwind
"The best part about taking Resend into production was that there was no friction at all."Tara NagarSoftware Engineer at Braintrust
"The flexibility of Resend is what we value most. It allows us to quickly adapt and refine our email communications as our products evolve."Glauber CostaFounder and CEO at Turso
"Resend is email with simpler APIs, better webhooks, and best-in-class debugging."Dan FarrellyCTO and Co-Founder of Inngest
"Our team loves Resend. It makes email sending so easy and reliable. After we switched to Dedicated IPs, our deliverability improved tremendously and we don't hear complaints about emails landing on spam anymore."Vlad MatsiiakoCo-founder of Infisical
"As a developer I love the approach that the Resend team is taking. Its so refreshing. They are also extremely user-centric and helpful in terms of getting you up and running, sending beautiful emails that deliver."Hahnbee LeeCo-Founder at Mintlify
"We value tools that feel stable, well thought out, and aligned with the standards we expect across our stack. Resend meets those expectations. It lets our team stay focused on building the larger platform rather than getting pulled into the overhead that typically comes with legacy email infrastructure."Bradley GreenwoodVP of Engineering at MrBeast
"Our partnership with Resend has been a great experience. They've made sure we can focus on what we do best—building our product and growing our business."Sahil LavingiaCEO of Gumroad
"Switching over to Resend from SendGrid marked a significant improvement in our email management. We started with a small test - waitlist emails for our iOS and Windows apps. Within 30 minutes, we were done."Thomas MannFounder & CEO of Raycast
"The simplicity and reliability of Resend allowed our engineers to focus on building features rather than troubleshooting email infrastructure."Amadeo PellicceConnectors, Agents and Automations Lead at Replit
"We're a small team with a lot on our plates. Email infrastructure is something we don't want to think about, and with Resend we don't have to."Peter SuhmOps at Tailwind
"The best part about taking Resend into production was that there was no friction at all."Tara NagarSoftware Engineer at Braintrust
"The flexibility of Resend is what we value most. It allows us to quickly adapt and refine our email communications as our products evolve."Glauber CostaFounder and CEO at Turso
"Resend is email with simpler APIs, better webhooks, and best-in-class debugging."Dan FarrellyCTO and Co-Founder of Inngest
"Our team loves Resend. It makes email sending so easy and reliable. After we switched to Dedicated IPs, our deliverability improved tremendously and we don't hear complaints about emails landing on spam anymore."Vlad MatsiiakoCo-founder of Infisical
"As a developer I love the approach that the Resend team is taking. Its so refreshing. They are also extremely user-centric and helpful in terms of getting you up and running, sending beautiful emails that deliver."Hahnbee LeeCo-Founder at Mintlify
"We value tools that feel stable, well thought out, and aligned with the standards we expect across our stack. Resend meets those expectations. It lets our team stay focused on building the larger platform rather than getting pulled into the overhead that typically comes with legacy email infrastructure."Bradley GreenwoodVP of Engineering at MrBeast
"Our partnership with Resend has been a great experience. They've made sure we can focus on what we do best—building our product and growing our business."Sahil LavingiaCEO of Gumroad
"Switching over to Resend from SendGrid marked a significant improvement in our email management. We started with a small test - waitlist emails for our iOS and Windows apps. Within 30 minutes, we were done."Thomas MannFounder & CEO of Raycast
"The simplicity and reliability of Resend allowed our engineers to focus on building features rather than troubleshooting email infrastructure."Amadeo PellicceConnectors, Agents and Automations Lead at Replit
"We're a small team with a lot on our plates. Email infrastructure is something we don't want to think about, and with Resend we don't have to."Peter SuhmOps at Tailwind
"The best part about taking Resend into production was that there was no friction at all."Tara NagarSoftware Engineer at Braintrust
"The flexibility of Resend is what we value most. It allows us to quickly adapt and refine our email communications as our products evolve."Glauber CostaFounder and CEO at Turso
"Resend is email with simpler APIs, better webhooks, and best-in-class debugging."Dan FarrellyCTO and Co-Founder of Inngest
Resend delivers mission-critical emails for some
of the fastest growing teams.