Cloudflare Email Service (beta): Guide to Comply with Gmail/Yahoo in 2025 Without Spending a Cent

Updated 2025-01-2621 words • 1m read

Cloudflare launches Email Service to send emails from Workers with auto-configured SPF, DKIM, and DMARC. Complete guide to meet new Gmail and Yahoo…

Cloudflare Email Service (beta): Guide to Comply with Gmail/Yahoo in 2025 Without Spending a Cent

What Changed in 2024–2025 and Why It Affects You

Gmail and Yahoo have significantly tightened requirements for bulk senders in 2024-2025. These changes affect any domain sending more than 5,000 emails per day to Gmail or Yahoo addresses.

Mandatory Requirements

  • SPF + DKIM + DMARC Authentication: All emails must authenticate correctly. DMARC must be configured with From domain alignment.
  • One-Click List-Unsubscribe: Mandatory implementation of List-Unsubscribe headers (with https:// URL and mailto: option) and List-Unsubscribe-Post for instant unsubscribe.
  • Complaint Rate < 0.3%: Keep user-reported spam complaints below the 0.3% threshold per Google Postmaster Tools.
  • Valid Reverse DNS: Sending servers must have correct PTR records.

Consequences of Non-Compliance

If you don't meet these requirements:

  • Your emails will be rejected or automatically marked as spam
  • Permanent damage to domain reputation
  • Possible complete blocking on Gmail and Yahoo

Three Ways to Send from Cloudflare Today

1. Cloudflare Email Service (Private Beta)

Cloudflare has launched Email Service in private beta, allowing you to send emails directly from Workers with native bindings.

Key Advantages

  • Auto-configured DNS: SPF, DKIM, and DMARC are configured automatically
  • Native Bindings: Direct integration in Workers without external HTTP calls
  • Ultra-low Latency: Execution at Cloudflare's edge
  • High Deliverability: Reputation managed by Cloudflare

Ideal Use Case

Critical transactional email: order confirmations, password resets, system notifications, where deliverability and speed are fundamental.

How to Request Access

Email Service is currently in private beta. Join the waiting list on Cloudflare's official blog or through the Cloudflare dashboard.

2. MailChannels Email API (100/day Free)

After the end of free integrated sending in Workers with MailChannels in 2023, the company launched its own free plan with 100 daily emails.

Advantages

  • Quick Sign-up: Immediate registration without waiting list
  • 100 Emails/Day Free: Sufficient for small and medium projects
  • Workers Compatible: Integration via REST API
  • SPF/DKIM Support: Manual configuration required

Limitations

  • Requires manual DNS configuration (SPF, DKIM)
  • Not as seamless as Cloudflare's native solution
  • 100 emails/day limit on free tier

When to Use It

Ideal for contact forms, blog notifications, small SaaS projects with moderate volume and limited budget.

3. External SMTP / Google Apps Script

Why NOT to Use Gmail with App Password

While technically possible, using your personal Gmail account with app passwords for production is discouraged:

  • Sending Limits: Maximum 500 recipients/day
  • Personal Reputation: Mixes your personal reputation with the application
  • Against Google Policies: Can result in account suspension
  • No Domain Authentication: Emails are sent from @gmail.com, not your domain

Webhook to Google Apps Script: When It Fits

For very low volumes (less than 20 emails/day), a webhook to Google Apps Script can work:

  • Occasional notifications from a personal form
  • Low-volume monitoring alerts
  • Hobby projects without strict deliverability requirements

Important: Not suitable for critical transactional email or newsletters.

2025 Compliance Checklist in 10 Minutes

1. Configure SPF, DKIM, and DMARC

Publish the following DNS records on your domain:

SPF (Sender Policy Framework)

TXT record on your root domain:

v=spf1 include:_spf.mailchannels.net ~all

Or for Cloudflare Email Service (when available):

v=spf1 include:_spf.cloudflare.com ~all

DKIM (DomainKeys Identified Mail)

MailChannels automatically generates DKIM keys. Add the provided TXT record from your dashboard.

DMARC (Domain-based Message Authentication)

TXT record on _dmarc.yourdomain.com:

v=DMARC1; p=none; rua=mailto:[email protected]

Recommended Progression:

  1. p=none: Monitoring mode (2-4 weeks)
  2. p=quarantine: Quarantine failures (2-4 weeks)
  3. p=reject: Full rejection of unauthenticated emails

2. Implement List-Unsubscribe and List-Unsubscribe-Post

Add these headers to all bulk emails:

List-Unsubscribe: <https://yourdomain.com/unsubscribe?token=xxx>, <mailto:[email protected]?subject=unsubscribe>
List-Unsubscribe-Post: List-Unsubscribe=One-Click

Unsubscribe Endpoint Implementation

  • The URL must respond with HTTP 200 to POST requests
  • Process the unsubscribe immediately (no additional confirmation)
  • List-Unsubscribe-Post header activates the unsubscribe button in Gmail/Yahoo

3. Monitor Metrics and DMARC Alignment

  • Google Postmaster Tools: Monitor reputation, spam complaints, and deliverability
  • Complaint Rate < 0.3%: Critical threshold
  • DMARC Alignment: The From domain must match SPF or DKIM

How to Set It Up Step by Step

Option A: Cloudflare Email Service (When Approved)

Once you have beta access:

1. Enable Email Service in Your Worker

// wrangler.toml
[[email_bindings]]
name = "EMAIL"

2. Send Emails with Native Binding

export default {
  async fetch(request, env) {
    await env.EMAIL.send({
      from: "[email protected]",
      to: "[email protected]",
      subject: "Order Confirmation",
      html: "<h1>Thank you for your purchase</h1>"
    });
    
    return new Response("Email sent", { status: 200 });
  }
};

3. Auto-configured DNS

Cloudflare automatically configures SPF, DKIM, and DMARC in your DNS zone. Verify in your Cloudflare dashboard.

Option B: MailChannels Email API (Available Now)

1. Sign Up for MailChannels

Create an account at support.mailchannels.com and get your API key.

2. Configure DNS Manually

// SPF
v=spf1 include:_spf.mailchannels.net ~all

// DKIM (get public key from dashboard)
default._domainkey TXT "v=DKIM1; k=rsa; p=YOUR_PUBLIC_KEY..."

// DMARC
_dmarc TXT "v=DMARC1; p=none; rua=mailto:[email protected]"

3. Example Worker with MailChannels

export default {
  async fetch(request, env) {
    const emailPayload = {
      personalizations: [{
        to: [{ email: "[email protected]" }],
        dkim_domain: "yourdomain.com",
        dkim_selector: "default"
      }],
      from: { email: "[email protected]", name: "My App" },
      subject: "Contact Form",
      content: [{
        type: "text/html",
        value: "<p>Message from form</p>"
      }],
      headers: {
        "List-Unsubscribe": "<https://yourdomain.com/unsubscribe?id=xxx>",
        "List-Unsubscribe-Post": "List-Unsubscribe=One-Click"
      }
    };

    const response = await fetch("https://api.mailchannels.net/tx/v1/send", {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
        "X-API-Key": env.MAILCHANNELS_API_KEY
      },
      body: JSON.stringify(emailPayload)
    });

    return new Response("Sent", { status: 200 });
  }
};

Measuring Success: Deliverability and Metrics

Google Postmaster Tools

Configure your domain at postmaster.google.com to monitor:

  • Domain and IP Reputation: High, Medium, Low, Bad
  • Spam Rate: Must stay < 0.3%
  • Authentication: % of emails passing SPF/DKIM/DMARC
  • Encryption: % of emails sent with TLS

Key Metrics to Track

  • Delivery Rate: % of emails reaching inbox (not spam)
  • Bounce Rate: Keep hard bounces < 2%
  • Time to Inbox: From sending to reception
  • Open Rate: Indicator of content relevance

DMARC Reports

Analyze aggregate reports (rua) to:

  • Detect domain spoofing attempts
  • Verify correct SPF/DKIM alignment
  • Identify unauthorized sending sources

Conclusion

The new Gmail and Yahoo requirements in 2025 raise the bar for all senders. Cloudflare Email Service arrives at the perfect time, offering a native solution with automatic DNS configuration. While waiting for beta access, MailChannels Email API (100/day free) and proper SPF, DKIM, and DMARC configuration allow you to comply at no additional cost.

The key to success lies in correct authentication, one-click List-Unsubscribe implementation, and continuous monitoring of deliverability metrics. Following this guide, your emails will reach the inbox in 2025 and beyond.

Related Tools

Related Articles

Read in Other Languages

FAQ

  • What changed with Gmail and Yahoo requirements in 2025?
    Gmail and Yahoo now require SPF+DKIM+DMARC for all bulk senders, one-click unsubscribe (List-Unsubscribe and List-Unsubscribe-Post), and keeping spam complaints below 0.3%. Non-compliance results in rejection or spam folder placement.
  • What is Cloudflare Email Service?
    A service in private beta that allows sending emails directly from Cloudflare Workers with native bindings and automatic SPF, DKIM, and DMARC configuration. Ideal for high-deliverability transactional email.
  • What are the free alternatives?
    MailChannels Email API (100 emails/day free) and webhooks to Google Apps Script for very low volumes. Using Gmail with app passwords for production is not recommended due to reputation limits.
  • How do I implement List-Unsubscribe?
    Add the List-Unsubscribe header (with https:// URL and mailto:) and List-Unsubscribe-Post: List-Unsubscribe=One-Click. This enables one-click unsubscribe from the email client interface.

Count of local transformations you do here (convert, optimize, resize, crop, remove background). All done privately in your browser.