https://github.com/mozilla/readability Skip to content Toggle navigation Sign in * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions For + Enterprise + Teams + Startups + Education By Solution + CI/CD & Automation + DevOps + DevSecOps Resources + Learning Pathways + White papers, Ebooks, Webinars + Customer Stories + Partners * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} mozilla / readability Public * Notifications * Fork 552 * Star 7.3k * A standalone version of the readability lib License View license 7.3k stars 552 forks Branches Tags Activity Star Notifications * Code * Issues 222 * Pull requests 1 * Actions * Projects 0 * Security * Insights Additional navigation options * Code * Issues * Pull requests * Actions * Projects * Security * Insights mozilla/readability This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main BranchesTags Go to file Code Folders and files Last Last Name Name commit commit message date Latest commit History 487 Commits test test .eslintrc.js .eslintrc.js .gitattributes .gitattributes .gitignore .gitignore .npmignore .npmignore .release-it.json .release-it.json .taskcluster.yml .taskcluster.yml CHANGELOG.md CHANGELOG.md CODE_OF_CONDUCT.md CODE_OF_CONDUCT.md CONTRIBUTING.md CONTRIBUTING.md JSDOMParser.js JSDOMParser.js LICENSE.md LICENSE.md README.md README.md Readability-readerable.js Readability-readerable.js Readability.js Readability.js SECURITY.md SECURITY.md index.d.ts index.d.ts index.js index.js package-lock.json package-lock.json package.json package.json View all files Repository files navigation * README * Code of conduct * License * Security Readability.js A standalone version of the readability library used for Firefox Reader View. Installation Readability is available on npm: npm install @mozilla/readability You can then require() it, or for web-based projects, load the Readability.js script from your webpage. Basic usage To parse a document, you must create a new Readability object from a DOM document object, and then call the parse() method. Here's an example: var article = new Readability(document).parse(); If you use Readability in a web browser, you will likely be able to use a document reference from elsewhere (e.g. fetched via XMLHttpRequest, in a same-origin