A guide to formatting an RSS 2.0 feed so DEV.to imports your articles, images, and tags with zero formatting errors.
1. Quick Checklist: What to Do
- [ ] Wrap full article HTML inside
<content:encoded><![CDATA[...]]></content:encoded>. - [ ] Convert all image
src,srcset, and linkhrefattributes to absolute URLs (https://domain.com/...). - [ ] Sanitize tags (
<category>): alphanumeric only (a-z0-9), max 20 chars, max 4 tags per post. - [ ] Provide a unique
<guid isPermaLink="true">to prevent duplicate imports. - [ ] Provide cover images via
<enclosure>and as the first<img>inside<content:encoded>. - [ ] In DEV Settings, keep "Mark RSS source as canonical" checked and "Replace self-referential links" unchecked.
2. RSS Field Reference
<item> Fields
| Field | Requirement | What It Does on DEV.to |
|---|---|---|
<title> |
Required | Article headline. Escape XML special characters. |
<link> |
Required | Canonical link back to original post. |
<guid> |
Required | Unique ID. Prevents re-importing duplicates on sync. |
<content:encoded> |
Required | Full HTML body wrapped in <![CDATA[...]]>. Converted to Markdown by DEV. |
<description> |
Fallback | Excerpt/summary. Used as body only if <content:encoded> is missing. |
<pubDate> |
Recommended | UTC date (Wed, 19 Aug 2026 10:00:00 GMT). Sets publication/draft date. |
<category> |
Optional (Max 4) | Becomes post tags. Must be alphanumeric and $\le$ 20 chars. |
<enclosure> |
Optional | Sets the post's cover/hero image (type="image/webp" or image/png). |
<author> |
Optional | email@domain.com (Author Name) |
3. Strict Formatting Rules
Rule 1: Tags (<category>)
DEV.to rejects or corrupts tags that don't match [a-zA-Z0-9]:
-
Remove special chars:
next.js$\rightarrow$nextjs,web-dev$\rightarrow$webdev,c#$\rightarrow$csharp. - Truncate: Maximum 20 characters per tag.
- Limit: Maximum 4 tags per post.
Rule 2: Images & Links (Must Be Absolute)
DEV.to cannot resolve relative paths like /images/hero.png.
- ❌
<img src="/images/hero.png"> - ✅
<img src="https://yourdomain.com/images/hero.png"> - ❌
<a href="/blog/my-post"> - ✅
<a href="https://yourdomain.com/blog/my-post">
Rule 3: Cover Images
To ensure the cover image renders both as the header banner and in feed previews:
- Add
<enclosure url="https://yourdomain.com/cover.webp" type="image/webp" length="0" />. - Prepend
<p><img src="https://yourdomain.com/cover.webp" alt="..." /></p>to<content:encoded>.
4. Gist Templates
Template A: Minimum Viable RSS Feed
The bare minimum needed for DEV.to to ingest a post cleanly:
Template B: Full Production RSS Feed (With Tags, Covers & CDATA)
5. Copy-Paste Code Utilities (TypeScript)
Use these helper functions when building your RSS feed generator:
6. How to Configure DEV.to Settings
- Go to dev.to/settings/extensions.
- Scroll to "Publishing to DEV Community from RSS".
- Paste your feed URL (e.g.
https://yourdomain.com/rss.xml). - Set the options:
-
Mark the RSS source as canonical URL by default:
[x] Checked(Preserves your Google SEO ranking). -
Replace self-referential links with DEV Community-specific links:
[ ] Unchecked(Keeps internal links pointing to your website).
-
Mark the RSS source as canonical URL by default:
- Click "Submit feed settings" $\rightarrow$ Click "Fetch feed now".
- Go to dev.to/dashboard to view, edit, and publish your imported drafts.
Top comments (0)