← Sat, Oct 3 digest

RSS Feed Best Practices (2022)

read article ↗ hn thread ↗

A comprehensive guide outlines technical best practices for publishing reliable RSS and Atom feeds, recommending Atom for its clarity and absolute URLs for compatibility.

summary is enough A handy checklist for feed publishers, though the comment section provides essential real-world corrections regarding CSS and styling support in actual readers.

summary

This guide details technical best practices for publishing RSS and Atom feeds to ensure maximum compatibility across readers. It covers critical implementation details like choosing Atom, using absolute URLs, setting proper content types, and issuing persistent entry IDs. Additional optimizations include static caching, conditional requests, and CORS headers to improve performance and polling efficiency. While comprehensive, developers should cross-reference its styling advice with real-world limitations noted by feed reader authors in the comments.

key points

  1. Prefer Atom over RSS 2 for its simpler specification and lower ambiguity regarding compatibility.
  2. Use absolute URLs everywhere, including inside post HTML bodies, to prevent broken links in clients.
  3. Ensure entry IDs are globally unique, immutable, and preferably mapped directly to article permalinks.
  4. Implement conditional requests (ETags and Last-Modified headers) and CORS headers to support client-side readers and reduce server load.

who should read it

Bloggers and developers building or maintaining syndication feeds for websites or platforms.

discussion positive

consensus

Commenters generally agree with the core recommendations while adding fine-grained technical insights and corrections.

pushback

An RSS reader developer heavily criticizes the styling section, pointing out that real-world readers ignore or strip most CSS and custom tags.

best comment by tjansen ↗

As the author of an RSS reader, I would agree with most of that article, except the HTML / Styling section. It is full of misleading information.

1. You can use CSS, but expect that most readers will completely ignore it. Even widespread ones, like Feedly. Those that do support it will only offer a small subset, like text styles. No layout styles (positioning or flex-layouts), often not even colors. If you want to try the capabilities of your reader, this is a test feed: https://test-rss.downread.com/styles.rss.xml

2. Don't just prefer inline CSS, use it, because any sane RSS reader will …

An RSS reader author provides vital real-world context on how production clients handle CSS, inline styles, and embedded media, correcting the article's advice.

Generated by an LLM from the article and thread. Check the sources before relying on it.