Skip to main content

A simple package to extract text from (even broken/invalid) HTML. No dependencies, it just uses Python's internal HTMLParser with a few tweaks.

Usage:

from html_stripper import strip_tags
text = strip_tags("<html>…")
from html_stripper import strip_tags
import requests
strip_tags(requests.get("https://foo.bar/").text)
from html_stripper import strip_tags, strip_multiple_newlines
text = strip_multiple_newlines(strip_tags("<html>…")) # replaces chained newlines with a single \n

Release files for html-stripper 0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for html-stripper 0.3
File Size Uploaded
html_stripper-0.3.tar.gz 15.2 kB Details

Release files / html_stripper-0.3.tar.gz

Download URL html_stripper-0.3.tar.gz
Size 15.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b9ea66bc75d00adc06447f3c3a278899c10cf12fad0c0faab39457057b4056b9
BLAKE2b-256 checksum
How to use checksums
21e0c6b141679eed08bb139a7a82f36ed30336b15d69c9b2c4a735549a53efad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.6.11

Release history Release notifications | RSS feed

This release

0.3 This release

1 release file

0.2.1

1 release file

0.2

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page