defuddle
AGENTS.md9.8k starsChanged 49 days agoMITView on GitHub
Extracts main content from web pages as clean HTML. Changes must work across these environments:
Trending
More talk lately.about the whole repository
Who's talking about kepano/defuddle
- A Hacker News story“Show HN: Defuddle, an HTML-to-Markdown alternative to Readability”Hacker News · May 22, 2025 · 418 points
- @stephango.com“yes, that's exactly what defuddle is github.com/kepano/defud...”Bluesky · Mar 4, 2026 · 5 likes
- tridactyl/tridactyl“consider switching to defuddle for :reader”GitHub · Aug 30, 2026 · 2 reactions
- giselles-ai/giselle“chore(deps): bump the npm_and_yarn group across 1 directory with 2 updates”GitHub · Mar 11, 2026 · 2 reactions
- @github-trending-js.bsky.social“🔥 Hot Repo! 🔥 (100+ new stars) 📦 kepano / defuddle ⭐ 3,810 (+120) 🗒 TypeScript Extract the main content …”Bluesky · Mar 6, 2026 · 2 likes
The biggest 5 of 60 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 60
Talked about on GitHub, Bluesky, Hacker News and the web (60 times).
On GitHub · 50
- Aug 30, 2026consider switching to defuddle for :reader — tridactyl/tridactyl2 reactions · 2 comments
- Mar 11, 2026chore(deps): bump the npm_and_yarn group across 1 directory with 2 updates — giselles-ai/giselle2 reactions · 4 comments
- Oct 21, 2026chore: bump the production-dependencies group across 1 directory with 22 updates — mengxi-ream/read-frog1 reaction · 3 comments
- Oct 18, 2026chore: bump the production-dependencies group across 1 directory with 21 updates — mengxi-ream/read-frog1 reaction · 3 comments
- Oct 15, 2026chore: bump the production-dependencies group with 11 updates — mengxi-ream/read-frog1 reaction · 3 comments
45 more on GitHub
- Sep 3, 2026chore: bump the production-dependencies group across 1 directory with 14 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Sep 2, 2026chore: bump the production-dependencies group across 1 directory with 13 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Aug 28, 2026chore: bump the production-dependencies group across 1 directory with 10 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Aug 27, 2026chore: bump the production-dependencies group with 11 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Jul 27, 2026chore: bump the production-dependencies group across 1 directory with 17 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Jul 25, 2026chore: bump the production-dependencies group across 1 directory with 19 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Jul 23, 2026chore: bump the production-dependencies group across 1 directory with 12 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Jul 2, 2026chore: bump the production-dependencies group across 1 directory with 11 updates — mengxi-ream/read-frog1 reaction · 2 comments
- Mar 12, 2026Integrate Defuddle for higher-quality YouTube transcript formatting — thurstonsand/anypod1 reaction · 2 comments
- Mar 3, 2026Add defuddle as an alternative to readabiltiy / mercury — ArchiveBox/abx-plugins1 reaction
- Nov 9, 2026deps(deps): bump the production-dependencies group across 1 directory with 9 updates — Songmu/mdhq0 reactions
- Nov 7, 2026Slice 7d1: GitHub repositories through the REST API — KyaniteHQ/threadsift0 reactions · 1 comment
- Nov 6, 2026yakala isle: Defuddle bölüm atlıyor, eksik metin uyarısız "cikarildi" oluyor — avenoxai/avenoxbeyin0 reactions · 3 comments
- Nov 6, 2026Slice 7a: article text through Defuddle — KyaniteHQ/threadsift0 reactions · 2 comments
- Nov 5, 2026chore(deps): bump defuddle from 0.19.5 to 0.19.6 — murashit/codex-panel0 reactions
- Nov 4, 2026chore(deps): bump defuddle from 0.19.5 to 0.19.6 — gleanary/gleanary0 reactions · 1 comment
- Nov 2, 2026deps: bump defuddle from 0.19.5 to 0.19.6 — khlebobul/speed-reader0 reactions · 1 comment
- Nov 2, 2026chore(deps): bump defuddle from 0.19.5 to 0.19.6 in the npm-minor-patch group — apmantza/pi-webaio0 reactions · 1 comment
- Nov 2, 2026deps(deps): bump defuddle from 0.19.4 to 0.19.6 — pokutuna/mcp-chrome-tabs0 reactions · 1 comment
- Nov 2, 2026chore(deps): bump defuddle from 0.19.5 to 0.19.6 — TianZuo555/pi-extensions0 reactions
- Nov 2, 2026build(deps): bump defuddle from 0.19.5 to 0.19.6 in /obsidian-plugin — cavi-ai/claude-obsidian0 reactions
- Nov 2, 2026Bump defuddle from 0.19.5 to 0.19.6 — speed-reader-pro/speed_reader_web_app0 reactions · 1 comment
- Nov 1, 2026build(deps): bump defuddle from 0.19.1 to 0.19.6 — ayagmar/pi-codex-web-search0 reactions · 1 comment
- Nov 1, 2026build(deps): bump defuddle from 0.19.5 to 0.19.6 — wannli/obsidian-reader0 reactions
- Nov 1, 2026build(deps): bump defuddle from 0.19.4 to 0.19.6 — hafacc/repub0 reactions
- Oct 31, 2026chore(deps): bump defuddle from 0.19.5 to 0.19.6 — igorsaevets/page2ai-benchmark0 reactions
- Oct 30, 2026chore(deps): bump defuddle from 0.19.2 to 0.19.6 in /suites/context-economy/adapters/defuddle — TIKAZI/TIKAZ-AI-Skills0 reactions
- Oct 30, 2026build(deps): bump defuddle from 0.19.2 to 0.19.6 in /adapters/defuddle — TIKAZI/TIKAZ-Codex-Context-Economy0 reactions
- Oct 29, 2026Bump defuddle from 0.19.5 to 0.19.6 — 3-ark/Cognito-AI_Sidekick0 reactions
- Oct 27, 2026Bump defuddle from 0.19.5 to 0.19.6 — BoboDupla/wclip0 reactions
- Oct 26, 2026build(deps): bump the routine-minor-patch group across 1 directory with 3 updates — huyanxius/everplain0 reactions
- Oct 25, 2026chore(deps): bump the production-dependencies group across 1 directory with 3 updates — myyimu/sift-ai0 reactions
- Oct 22, 2026chore(deps): bump defuddle from 0.19.4 to 0.19.5 — murashit/codex-panel0 reactions
- Oct 19, 2026deps(deps): bump defuddle from 0.19.4 to 0.19.5 — pokutuna/mcp-chrome-tabs0 reactions · 1 comment
- Oct 18, 2026build(deps): bump defuddle from 0.19.4 to 0.19.5 — wannli/obsidian-reader0 reactions
- Oct 14, 2026Bump defuddle from 0.19.4 to 0.19.5 in the production-dependencies group across 1 directory — benoiteveillard/clipper-for-tolaria0 reactions · 1 comment
- Oct 11, 2026Import a web article by URL as a Markdown note and read it in the reader (with a coverage preview) — davadev/obsidian_chinese_comprehensible_input0 reactions · 1 comment
- Oct 7, 2026Bump defuddle from 0.19.1 to 0.19.5 — hraness/wordcell0 reactions · 1 comment
- Sep 22, 2026[GHSA-5mq8-78gm-pjmq] defuddle vulnerable to XSS via unescaped string interpolation in _findContentBySchemaText image tag — github/advisory-database0 reactions · 2 comments
- Sep 1, 2026Bump defuddle from 0.19.1 to 0.19.3 in /assets/extension — apcar/PageParcel0 reactions
- Aug 30, 2026chore(deps): bump defuddle from 0.12.0 to 0.19.3 in /skills/baoyu-url-to-markdown/scripts — xkl0305/xiaoyiCIaw0 reactions
- Aug 29, 2026chore(deps): bump defuddle from 0.17.0 to 0.19.1 — DevZonayed/nexalance-skill-jimliu-baoyu-skills0 reactions
- Aug 27, 2026v0.25.0 Defuddle fallback logs a raw stack into Pi while returning the fetch as successful — nicobailon/pi-web-access0 reactions
- Aug 25, 2026chore(deps): bump the npm_and_yarn group across 2 directories with 1 update — bdsqqq/dots0 reactions
- Aug 24, 2026Defuddle as Mozilla Readability Alternative — nicobailon/pi-web-access0 reactions · 1 comment
On Bluesky · 8
- Mar 4, 2026yes, that's exactly what defuddle is github.com/kepano/defud... — @stephango.com5 likes and reposts · 1 reply
- Mar 6, 2026🔥 Hot Repo! 🔥 (100+ new stars) 📦 kepano / defuddle ⭐ 3,810 (+120) 🗒 TypeScript Extract the main content from web pages. — @github-trending-js.bsky.social2 likes and reposts
- May 23, 2025Readability를 대체하는 HTML-to-Markdown 오픈소스 도구 Defuddl | GeekNews news.hada.io/topic?id=21069 kepano/defuddle: Extract the main content from… — @lunamoth.bsky.social1 likes and repost
- May 23, 2025https://github.com/kepano/defuddle Defuddleは、Webページから不要な要素を取り除き、読みやすくするツールです。 コメント、サイドバー、ヘッダーなどを削除し、主要コンテンツのみを残します。 Obsidian Web… — @topickapp.bsky.social1 likes and repost
- May 22, 2025Show HN: Defuddle, an HTML-to-Markdown alternative to Readability https://github.com/kepano/defuddle… — @betterhn20.e-work.xyz1 likes and repost
3 more on Bluesky
- May 22, 2025Show HN: Defuddle, an HTML-to-Markdown alternative to Readability Defuddle is an open-source libr... https://github.com/kepano/defuddle… — @mozilla.activitypub.awakari.com.ap.brid.gy1 likes and repost
- Aug 31, 2026This makes it pretty close github.com/kepano/defud... Also works on some YouTube videos — @elliotcsmith.com0 likes and reposts · 1 reply
- May 23, 2025Show HN: Readabilityに代わるHTML-to-Markdown「Defuddle Show HN: Defuddle, an HTML-to-Markdown alternative to Readability 🔺 280 💬 25 🔗 HN Post… — @hacker-news-jp.bsky.social0 likes and reposts · 1 reply
On Hacker News · 1
- May 22, 2025Show HN: Defuddle, an HTML-to-Markdown alternative to Readability418 points · 68 comments
On the web · 1
- May 22, 2025Defuddle, an HTML-to-Markdown alternative to Readability — hn.nuxt.dev
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,439 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
The file
We split this AGENTS.md into the rules it gives an agent
3 rules. About 0 are common, 0 are distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 7
Never use innerHTML directly.
- Very specific: line 19
Always use curl to test the Worker or defuddle.md.
- Very specific: line 33
Start with { debug: true } and inspect result.debug.removals and result.debug.contentSelector.
≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Defuddle
Extracts main content from web pages as clean HTML.
Security
- Never use
innerHTMLdirectly. UseparseHTML()fromsrc/utils/dom.ts(template-based parsing without script execution or resource loading). - Escape every page-derived value interpolated into HTML with
escapeHtml(), or build nodes withcreateElement/setAttributeandserializeHTML(). Downstream sanitization does not replace escaping at the point of interpolation. - Strip
javascript:,blob:, and non-imagedata:URLs fromhref/src. Allowdata:image/*except as an iframesrc. Strip iframesrcdocand allon*event handlers. - Preserve sanitization regardless of pipeline options. See
isDangerousUrl()insrc/utils/dom.tsand_stripUnsafeElements()insrc/defuddle.ts. - Cover new extractors with a poisoned-attribute case in
tests/extractor-xss.test.ts.
Build and test
npm run build— build all bundles.npm test— run Vitest.- For extraction fixes, add a minimal HTML fixture in
tests/fixtures/with correct expected output intests/expected/. Verify the same fixture fails before the fix and passes afterward; do not change expectations to match buggy behavior. - Anonymize fixtures: replace real names, emails, URLs, and identifying content with generic placeholders.
- Always use
curlto test the Worker or defuddle.md; never open those URLs in a browser. - Local Worker: run
cd website && npx wrangler dev, thencurl http://localhost:8787/https://stephango.com/saw. - Production:
curl https://defuddle.md/https://stephango.com/saw.
Runtime compatibility
Changes must work across these environments:
- Browser (
defuddle,defuddle/full): native DOM. - Node.js (
defuddle/node): async API accepting any DOMDocument, including linkedom, JSDOM, and happy-dom. - CLI (
src/cli.ts) and Cloudflare Worker (website/src/convert.ts): linkedom; the Worker is the most constrained environment.
Debugging extraction
- Start with
{ debug: true }and inspectresult.debug.removalsandresult.debug.contentSelector. Debug mode preserves class/id/data attributes and skips div flattening. - Disable removal steps individually to isolate content loss. Use
contentSelectorto bypass incorrect main-content detection. - For selector issues, inspect
EXACT_SELECTORSandPARTIAL_SELECTORSinsrc/constants.ts. Elements inside<pre>or<code>are protected from selector removal. - Standardize footnotes and callouts before removals: CSS sidenotes may use
display:none, and callout classes such as.alertotherwise match clutter selectors.
Common pitfalls
- UMD bundles use webpack
export: 'default'; expose named exports as static properties on the default class (seesrc/index.full.ts). getElementsByTagNamereturns live HTMLCollections. UseArray.from()before mutating the DOM.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

