email-best-practices
resend/resend-skills
Comprehensive guidance for building deliverable, compliant, and accessible emails.
What is email-best-practices?
Email Best Practices provides structured guidance for building email features that avoid spam filters, meet compliance requirements, and work for all users. Use it when setting up authentication, handling transactional or marketing emails, managing list hygiene, or ensuring accessibility.
- Set up SPF/DKIM/DMARC authentication to improve deliverability and prevent spam filtering
- Build transactional emails (password resets, OTPs, confirmations) with reliability and idempotency
- Implement email capture with double opt-in and consent tracking for marketing lists
- Ensure CAN-SPAM, GDPR, and CASL compliance for legal email sending
- Handle webhook events, retries, and suppression lists for production-ready sending
- Make emails accessible with proper alt text, headings, contrast, and screen reader support
How to install email-best-practices
npx skills add https://github.com/resend/resend-skills --skill email-best-practicesHow to use email-best-practices
- 1.Identify your email need using the Quick Reference table (deliverability, transactional, marketing, compliance, etc.)
- 2.Follow the recommended path for your use case (new app, spam issues, marketing, or production-ready)
- 3.Consult the relevant reference guide (e.g., Deliverability for authentication, Email Capture for signups)
- 4.Implement the practices and patterns documented in the selected reference
- 5.Validate compliance, authentication, and accessibility before sending to users
Use cases
- Diagnosing why emails are going to spam and fixing authentication issues
- Building a password reset or email verification flow for a new app
- Setting up a newsletter signup with proper consent and compliance
- Implementing bounce handling and suppression list management
- Creating accessible HTML emails that work across email clients and assistive technologies
- Backend developers building email features
- Full-stack engineers setting up transactional email systems
- Product teams launching marketing email campaigns
- DevOps engineers configuring DNS authentication
- Accessibility-focused developers ensuring email inclusivity
email-best-practices FAQ
Transactional emails (password resets, confirmations, receipts) are triggered by user actions and don't require opt-in. Marketing emails (newsletters, promotions) require explicit consent and must include unsubscribe options and comply with CAN-SPAM/GDPR/CASL.
Most commonly due to missing or misconfigured SPF/DKIM/DMARC authentication. Check the Deliverability reference first—Gmail and Yahoo reject unauthenticated emails. Also verify sender reputation and avoid spam trigger words.
Double opt-in (confirmation email after signup) improves list quality and compliance, especially under GDPR. Single opt-in is faster but risks higher bounce rates and spam complaints.
Use webhooks to listen for bounce and complaint events, then add those addresses to a suppression list. The List Management reference covers suppression strategies and list hygiene jobs.
Missing alt text on images, poor color contrast, no language tags, presentational tables instead of semantic markup, and missing title elements. See the Accessibility reference for a complete checklist.
Full instructions (SKILL.md)
Source of truth, from resend/resend-skills.
name: email-best-practices description: Use when building email features, emails going to spam, high bounce rates, setting up SPF/DKIM/DMARC authentication, implementing email capture, ensuring compliance (CAN-SPAM, GDPR, CASL), handling webhooks, retry logic, making emails accessible (alt text, headings, contrast, screen readers), or deciding transactional vs marketing. license: MIT metadata: author: Resend version: "1.0.2" homepage: https://resend.com/agent-skills source: https://github.com/resend/email-best-practices openclaw: links: repository: https://github.com/resend/email-best-practices documentation: https://resend.com/docs/email-best-practices-skill
Email Best Practices
Guidance for building deliverable, compliant, user-friendly emails.
Architecture Overview
[User] → [Email Form] → [Validation] → [Double Opt-In]
↓
[Consent Recorded]
↓
[Suppression Check] ←──────────────[Ready to Send]
↓
[Idempotent Send + Retry] ──────→ [Email API]
↓
[Webhook Events]
↓
┌────────┬────────┬─────────────┐
↓ ↓ ↓ ↓
Delivered Bounced Complained Opened/Clicked
↓ ↓
[Suppression List Updated]
↓
[List Hygiene Jobs]
Quick Reference
| Need to... | See |
|---|---|
| Set up SPF/DKIM/DMARC, fix spam issues | Deliverability |
| Build password reset, OTP, confirmations | Transactional Emails |
| Plan which emails your app needs | Transactional Email Catalog |
| Build newsletter signup, validate emails | Email Capture |
| Send newsletters, promotions | Marketing Emails |
| Ensure CAN-SPAM/GDPR/CASL compliance | Compliance |
| Decide transactional vs marketing | Email Types |
| Handle retries, idempotency, errors | Sending Reliability |
| Process delivery events, set up webhooks | Webhooks & Events |
| Manage bounces, complaints, suppression | List Management |
| Make emails accessible (screen readers, alt text, contrast) | Accessibility |
Start Here
New app? Start with the Catalog to plan which emails your app needs (password reset, verification, etc.), then set up Deliverability (DNS authentication) before sending your first email.
Spam issues? Check Deliverability first—authentication problems are the most common cause. Gmail/Yahoo reject unauthenticated emails.
Marketing emails? Follow this path: Email Capture (collect consent) → Compliance (legal requirements) → Marketing Emails (best practices).
Production-ready sending? Add reliability: Sending Reliability (retry + idempotency) → Webhooks & Events (track delivery) → List Management (handle bounces).
Accessibility?
Most emails fail basic accessibility checks. See Accessibility for lang/dir, presentational tables, headings, alt text, <title>, and contrast.
Related skills
More from resend/resend-skills and the wider catalog.
resend
Send, receive, and manage transactional emails with the Resend API—single/batch sends, webhooks, templates, and delivery tracking.
agent-email-inbox
Secure email inbox for AI agents with webhook-based receiving and built-in security patterns.
resend-cli
Terminal interface for Resend email platform — send emails, manage domains, contacts, templates, and more via CLI.
react-email
Build and send HTML emails using React components with a modern, component-based approach.