RSSFeeds.com

RSS to Email

RSS and email work well together. Publishers can turn their feed into an automatic newsletter, and readers can get new posts from any site in their inbox, one by one or as a daily digest.

Updated

Illustration of RSS feed items sent automatically as email

For Publishers: an Automatic Newsletter

Most email marketing platforms can watch your RSS feed and send new posts to your subscribers automatically. You design the template once; the platform fills it with the latest items on a schedule.

PlatformFeature
MailchimpRSS campaigns: daily, weekly or monthly emails built from your feed
MailerLiteRSS campaigns with a feed block in the email editor
Kit (formerly ConvertKit)RSS-to-email broadcasts and digests
ButtondownAutomatic emails for new feed items

Features and plans change, so check the platform's current documentation. Whatever you use, a clean feed makes the emails better:

  • Add a featured image per item (media:content or an image enclosure) so the template can show it.
  • Write real summaries in description; many templates show only those.
  • Use absolute URLs for images inside your content.
  • Validate the feed first with the Feed Validator; a broken item can stop a campaign.

For Readers: Feeds in Your Inbox

  • RSS-to-email services such as Blogtrottr send each new item, or a digest, to your email address. Paste the site or feed URL and choose the frequency.
  • Your feed reader: power readers like Inoreader can email items that match rules.
  • Automation tools: Zapier, Make and IFTTT can email new items, optionally filtered by keyword.
  • Google Alerts work the other way round: they can deliver to RSS instead of email; see Google News RSS Feed.

Prefer the opposite – newsletters in your feed reader? See How to Use RSS Feeds.

Self-Hosted: a Daily Digest Script

This PHP script collects new items from several feeds and sends one HTML email per day. It uses our RSS to JSON API to read RSS, Atom and JSON Feed alike, and PHP's mail(); swap in PHPMailer or your SMTP library for better deliverability.

rss-digest.php
<?php
$feeds = ['https://example.com/feed.xml', 'https://news.google.com/rss/search?q=%22your+brand%22&hl=en-US&gl=US&ceid=US:en'];
$to = 'you@example.com';
$stateFile = __DIR__ . '/digest-seen.json';
$e = fn($s) => htmlspecialchars($s, ENT_QUOTES, 'UTF-8');

$seen = is_file($stateFile) ? json_decode(file_get_contents($stateFile), true) : [];
$html = '';

foreach ($feeds as $feed) {
    $data = json_decode(@file_get_contents('https://rssfeeds.com/api/v1/feed?nocontent=1&count=20&url=' . urlencode($feed)), true);
    if (($data['status'] ?? '') !== 'ok') continue;
    $new = '';
    foreach ($data['items'] as $item) {
        $id = $item['guid'] ?: $item['link'];
        if (isset($seen[$id])) continue;
        $seen[$id] = time();
        $new .= '<li><a href="' . $e($item['link']) . '">' . $e($item['title']) . '</a><br><small>' . $e(mb_substr($item['description'], 0, 200)) . '</small></li>';
    }
    if ($new) $html .= '<h2>' . $e($data['feed']['title']) . '</h2><ul>' . $new . '</ul>';
}

if ($html) {
    $headers = ['MIME-Version: 1.0', 'Content-Type: text/html; charset=UTF-8', 'From: Digest <digest@example.com>'];
    mail($to, 'Your daily feed digest – ' . date('j M Y'), '<html><body style="font-family:sans-serif">' . $html . '</body></html>', implode("\r\n", $headers));
}

arsort($seen);
file_put_contents($stateFile, json_encode(array_slice($seen, 0, 5000, true)));
crontab: every day at 07:00
0 7 * * * php /home/user/scripts/rss-digest.php

The first run sends everything that is currently in the feeds; after that, only new items.

RSS vs Email Newsletters

RSSEmail
Subscriber gives an email addressNoYes
Publisher knows who subscribesNoYes
Can end up in spamNoYes
ReachFeed reader usersAlmost everyone
Open and click trackingLimitedYes

Publishers get the best of both by offering a feed and an email option side by side, with the newsletter generated from the feed.

Sources and Further Reading