types-html5lib
Typing stubs for html5lib
Decision gist · record as of 2026-08-14
Yes, if you use html5lib and run static type checking. It has no runtime cost, low install friction, and is actively maintained as part of typeshed. If you don't use a type checker or don't use html5lib, it provides no value. Apache-2.0 licensing poses no restrictions.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later; only provides type information, not runtime functionality—html5lib itself must be installed separately.
- Low install friction; a pure-Python wheel with a single lightweight runtime dependency (types-webencodings).
- Maintained actively as part of the typeshed project with recent commits.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 permissive license allows use in most projects without restriction; suitable for both open-source and commercial work.
last release 2026-05-18 (88 days) · last repo commit 2026-08-14 · 37 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 10,191,646 downloads/mo, #1,472 on PyPI
Alternatives
Verify before relying
pip install types-html5lib
# In your code, import html5lib normally; type checkers will use the stubs
import html5lib
parser = html5lib.HTMLParser()
doc = parser.parse("<html></html>")- Coverage of html5lib 1.1.x API surface completeness beyond the tested type checkers (mypy 2.1.0, pyright 1.1.409).
- Whether stubs remain synchronized with html5lib releases after the typeshed commit date.
What it is and what it does
types-html5lib is a type stub package that bridges the gap between the html5lib HTML parser and static type checkers. It provides type annotations for html5lib's public API, allowing mypy, pyright, and other type checkers to validate code that uses html5lib without runtime overhead. The stubs are maintained as part of the typeshed project and are tested against current versions of major type checkers.
When installed alongside html5lib, this package enables developers to catch type-related bugs during development rather than at runtime. It targets html5lib version 1.1.x and requires Python 3.10 or later. The package has a single runtime dependency (types-webencodings) and is distributed as a pure wheel, making installation straightforward.
Use it for
- Enable mypy or pyright to type-check code that parses HTML with html5lib in a CI/CD pipeline.
- Develop HTML parsing applications with IDE autocomplete and type hints for html5lib methods and classes.
- Validate type safety in projects that combine html5lib with other typed libraries in a large codebase.
- Ensure compatibility between html5lib usage and strict type-checking configurations.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you use html5lib and run static type checking.
It has no runtime cost, low install friction, and is actively maintained as part of typeshed. If you don't use a type checker or don't use html5lib, it provides no value. Apache-2.0 licensing poses no restrictions.
Install
types-html5lib on PyPI
Before you install
Low install friction; a pure-Python wheel with a single lightweight runtime dependency (types-webencodings). Maintained actively as part of the typeshed project with recent commits.
Requires Python 3.10 or later; only provides type information, not runtime functionality—html5lib itself must be installed separately.
License in practice
Apache-2.0 permissive license allows use in most projects without restriction; suitable for both open-source and commercial work.
Quickstart
pip install types-html5lib
# In your code, import html5lib normally; type checkers will use the stubs
import html5lib
parser = html5lib.HTMLParser()
doc = parser.parse("<html></html>")
Verify before relying
- Coverage of html5lib 1.1.x API surface completeness beyond the tested type checkers (mypy 2.1.0, pyright 1.1.409).
- Whether stubs remain synchronized with html5lib releases after the typeshed commit date.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 1 packagetypes-webencodings |
| Maintenance | Actively maintained 88 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 10,191,646 / month, #1,472 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Programming Language :: Python :: 3Typing :: Stubs Only |
Evidence: types_html5lib-1.1.11.20260518-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “type stubs html5lib”
- types-html5libProvides type hints for the html5lib HTML parser, enabling static…
- html5libhtml5lib parses HTML documents into a tree structure conforming to…
- types-assertpyProvides type stubs enabling static type checkers like mypy and…
Give your agent the search over MCP, or paste the wish link into any chat.
More HTML packages
MarkupSafe provides a text object that escapes special characters so untrusted strings can be safely embedded in HTML and XML without injection attacks.
Jinja2 is a templating engine that renders dynamic content by combining templates with Python-like syntax and data, supporting template inheritance, macros, autoescaping, and sandboxed execution.
Beautiful Soup parses HTML and XML documents into a navigable tree, providing Pythonic methods to search, iterate, and modify the parsed content.
Install it if you need to parse or extract data from markup documents.
lxml provides Python bindings to libxml2 and libxslt, enabling parsing, validation, and transformation of XML and HTML documents through an ElementTree-compatible API with support for XPath, XSLT, and schema validation.
Install it if you need robust XML/HTML parsing, validation, or transformation; avoid it only if you must stay pure-Python and can accept slower performance.
Docutils converts plaintext documentation in reStructuredText format into multiple output formats including HTML, XML, and LaTeX using a modular processing system.
Converts Markdown text to HTML using a Python implementation of John Gruber's Markdown specification, with support for extensions.
Install it if you need to parse Markdown in Python.
See also types-aiofiles · types-python-http-client · types-toml · types-uWSGI · types-xlrd · types-zxcvbn · types-webencodings · types-jsonschema · types-chevron · types-defusedxml