jusText
Heuristic based boilerplate removal tool
What it is and what it does
jusText is a heuristic-based tool for extracting main content from HTML pages by filtering out boilerplate elements like navigation, headers, and footers. It operates by analyzing text density and sentence structure, making it particularly suited for building linguistic corpora and web-scraped datasets where clean, sentence-bearing text is needed.
The package provides both a command-line interface (via `python -m justext`) and a Python API. It depends on lxml for HTML parsing and includes language-specific stoplists to improve detection accuracy. The core algorithm preserves paragraphs containing full sentences while marking others as boilerplate, allowing you to filter results programmatically.
Use it for:
- Build web corpora for natural language processing by extracting clean text from crawled HTML pages
- Preprocess web content before feeding it into linguistic analysis or text processing pipelines
- Automate extraction of article text from news sites or blogs while discarding navigation and ads
- Clean HTML snapshots for archival or readability analysis in web preservation workflows
- Remove noise from web-scraped training data for text classification or language models
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
jusText removes boilerplate content (navigation, headers, footers) from HTML pages while preserving text with full sentences, useful for extracting clean content for linguistic analysis and web corpora.
Yes, with conditions. The package is stable (Production/Stable classifier), permissively licensed, and has low install friction. However, maintenance is aging (535 days since last release), so it is best suited for established use cases where the algorithm is known to work well for your content type. Verify that lxml compiles on your target platform and that boilerplate detection accuracy meets your needs before production use.
Install
justext on PyPI
pip
pip install justextuv
uv add justextpoetry
poetry add justextInstalling jusText
Before you install
Low friction: pure Python wheel, only two runtime dependencies (lxml and backports.functools-lru-cache). Maintenance status is aging—last release 535 days ago, but repository is active (last commit 2025-02-25) with no archived flag.
License in practice
BSD 2-Clause License (permissive). No restrictions on commercial use, modification, or redistribution; standard permissive terms apply.
Quickstart
import justext
paragraphs = justext.justext(html_content, justext.get_stoplist("English"))
for paragraph in paragraphs:
if not paragraph.is_boilerplate:
print(paragraph.text)
lxml requires libxml2 and libxslt system libraries; may need compilation on some platforms.
Verify before relying
- Performance characteristics on very large HTML documents or high-throughput scenarios
- Accuracy of boilerplate detection across non-English languages and modern web layouts
- Whether backports.functools-lru-cache is still required on modern Python versions
Package facts
| License | The BSD 2-Clause License (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — lxml, backports.functools-lru-cache |
| Maintenance | aging — 535 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 11,719,151/month — #1,368 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: justext-3.0.2-py2.py3-none-any.whl
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
breadabilityExtracts the main readable content from HTML…
permissive · top 15,000 on PyPI
html-textExtracts plain text from HTML while filtering…
permissive · top 5,000 on PyPI
sumySumy extracts summaries from HTML pages or…
permissive · top 15,000 on PyPI
trafilaturaTrafilatura extracts main text, metadata, and…
permissive · top 5,000 on PyPI
readability-lxmlExtracts and cleans the main article text and…
permissive · top 5,000 on PyPI
inscriptisConverts HTML documents to plain text while…
permissive · top 5,000 on PyPI
html2textConverts HTML to clean, readable plain text or…
copyleft · top 5,000 on PyPI
docx2txtExtracts text, headers, footers, hyperlinks,…
unclear · top 5,000 on PyPI
parselParsel extracts data from HTML, JSON, and XML…
permissive · top 5,000 on PyPI