JSON Feed is a specification by Manton Reece and Brent Simmons for a
syndication format like RSS and Atom that uses JSON instead of XML.
Robb Knight posed the question:
Ignoring podcasts, which has to be RSS, is there an argument for using
RSS/atom over JSON feeds?
Ruben Schade responded with a thoughtful post citing several theories
as to why RSS/Atom feed are still the default:
- JSON Feed suffers the XKCD Standards Effect. Every blog has RSS support,
even those that implement JSON Feed. I’ve yet to encounter the reverse. If
JSON feed were offering anything more than an alternative serialisation
format, maybe it’d be more compelling. But RSS does the job, and adding
another standard didn’t offer much.
- JSON Feed was mostly a redundant format. As I wrote in 2017, if the issue
with RSS was XML, you could directly serialise RSS with JSON. JSON Feed was
entirely new, which requires you to reimplement everything to do… what you
can already do with an existing tool. Meh.
- JSON Feed solved a problem for developers, not users. People who write
material that end up in feeds, and the people who read those feeds,
couldn’t give a toss what the format is written in. Those of us in the
industry forget this at our peril, every single time.
These are great points and it seems unlikely that JSON Feed will displace RSS and
Atom as the default syndication formats in use. However, I want to discuss that
last point a little more.
Ruben is right that the typical visitor that wants to subscribe to your website
doesn’t care what the format is, as long it works in their feed reader.
Although I’d argue that developers that want to make use of content in a
machine readable form are users too. And for that purpose JSON is way easier to
handle than XML. Here’s a couple of examples of that in practice:
- The unreleased tool that posts each new post on this site to Mastodon uses
the JSON Feed as the source of posts.
- This tutorial used the JSON Feed from Read Rust (an
earlier project of mine) to build a CLI tool for the site.
It’s also easy to consume JSON on the command line with curl
and jq
/jaq
.
For example, this command line lists all the posts in the Linked List JSON Feed
that are tagged with ‘retro‑computing’:
$ curl -s https://linkedlist.org/feed.json | \
jaq '.items | map(select(.tags | contains(["retro-computing"]))) | .[].title'
"More Than You Ever Wanted to Know About the Windows 3.1 Graphics Stack"
All that is to say I think JSON Feed has utility even if it doesn’t replace XML
based feeds. I think of JSON Feed as an additional representation of my
website, not a replacement for RSS and Atom feeds. As I a result I offer both,
so visitors can use whatever format makes sense for their use-case.