Building a standalone RSS-to-Mastodon bridge

I’ve been working to minimize hosting requirements and to reduce external dependencies for my website. I now have simple, lightweight, self-hosted search and commenting functionality. The only external dependency remaining was the way new posts were cross-published to Mastodon.

I’d been using the excellent Mastofeed service. Mastofeed works great! If you’re looking for a hosted (free!) solution, definitely check it out. You authorize it to post items to a Mastodon account, and it automatically toots whenever you publish something on a website by checking the RSS feed for new items. Easy peasy. But it’s an external dependency - it could disappear, or change, or start inserting ads or something, or who knows?

I wasn’t overly concerned about the risks, but I was playing around with Claude Code and wondered what it would look like to build a standalone Fediverse integration for my website. My goal was to have a simple, lightweight thing - ideally nothing more complex than basic PHP and SQLite, that could be run on any commodity webserver with no need for NodeJS or frameworks or MySQL/MariaDB etc. etc.

The first version was a full Fediverse Actor - so people on Mastodon (or whatever Fediverse thing they use) would be able to subscribe to @blog@darcynorman.net and/or @photos@darcynorman.net and get notified when new content is published. Claude figured the easiest way to do this was to build an RSS-to-Fediverse bridge, with the ActivityPub stuff basically acting as a proxy. And it worked great!

But it wasn’t really a full Fediverse implementation - there was no way to reply (you could reply to a post on Mastodon, but there was nothing monitoring those so there was no way to actually have a conversation). Thanks to Alan for pointing this out. I tasked Claude with proposing options for enabling full conversations/responses and it came up with a few. But they basically involved building a mini Mastodon server, which is not what I wanted.

So, I had Claude start over from scratch, but integrating an RSS feed with an existing Mastodon account. Basically, recreating Mastofeed as a simple, standalone, self-hosted application. Which it did, and it works great. I can now have both my main feed and my photos feed cross-tooted to my Mastodon account, and responses etc can happen there without trying to integrate them with my comments application or pulling activity into the markdown files for my website.

Image representing RSS to Mastodon Bridge. It has icons and a bridge. It’s quite clever.

Here’s the publishing flow as used with my Hugo website:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚   Laptop    β”‚              β”‚   Server    β”‚
β”‚             β”‚              β”‚             β”‚
β”‚  Hugo Site  β”‚              β”‚ Static HTML β”‚
β”‚             β”‚   rsync      β”‚    Files    β”‚
β”‚   Build     β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Άβ”‚             β”‚
β”‚             β”‚              β”‚             β”‚
│  Deploy     │   webhook    │ RSS→Mastodon│
β”‚   Script    β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Άβ”‚   Bridge    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜              β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                                    β”‚
                                    β”‚ Mastodon API
                                    β”‚
                            β”Œβ”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
                            β”‚   Mastodon     β”‚
                            β”‚   Instance     β”‚
                            β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

But - Everything on the “Laptop” side could be ignored if you’re not using Hugo (replace with “Whatever CMS process you use”), and the “Bridge” component of the “Server” box could run anywhere.

The application transmorgified into Standalone RSS Mastodon Bridge. It’s on GitHub (as are my other self-hosting experiments: Standalone Comments and Hugo Lightweight Search ).

The bonus is that it should work for any RSS feeds, so it would be possible to set that up on any server (or just on your laptop or whatever) and publish any RSS feeds to any of your Mastodon accounts and cross-toot posts on the feeds. It (optionally) includes the first image in the RSS item.

Last updated: October 12, 2025