$npx skillfedfor your agent

dominate

Dominate is a Python library for creating and manipulating HTML documents using an elegant DOM API.

Worth itPyPI Python ModulesReleased Dec 20232.1M downloads / moLGPL-3.0-or-newerPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — dominate-2.9.1-py2.py3-none-any.whl
v2.9.1 · released 2023-12-24 · Python >=3.4

Yes. Dominate is a mature, actively maintained library with no dependencies, broad Python version support, and no known vulnerabilities. The copyleft license (LGPL-3.0) requires source disclosure if you distribute the library itself, but poses no barrier for internal or open-source use. Install it if you prefer writing HTML in Python over templates or string manipulation.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Installation is straightforward with no runtime dependencies.
  • The package is actively maintained with recent commits and a stable release history since 2013, supporting current Python versions (3.7–3.12 and PyPy).

License · maintenance · safety

LGPL-3.0-or-newer (copyleft) — Dominate is licensed under LGPL-3.0-or-newer (copyleft). If you distribute software that links or bundles this library, you must make your source code available under compatible terms.

last release 2023-12-24 (964 days) · last repo commit 2026-05-09 · 1,826 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 2,148,985 downloads/mo, #3,253 on PyPI

Verify before relying

pip install dominate

import dominate
from dominate.tags import div, p, html, body

doc = dominate.document(title='Example')
with doc:
    with div(id='content'):
        p('Hello, World!')

print(doc)
  • Performance characteristics when generating very large HTML documents or deeply nested structures.
  • Whether the library supports HTML5 semantic elements beyond standard tag coverage.
Same gist for agents: .md · .json

What it is and what it does

Dominate provides a Pythonic way to construct HTML by treating each HTML element as a Python class. You instantiate tags, nest them using context managers or method chaining, set attributes via keyword arguments or dictionary-like access, and render the result to a string. The library eliminates the need to write raw HTML or learn a separate templating syntax—instead, you write pure Python code that reads naturally and lets you use Python's full feature set (loops, conditionals, functions) to generate markup.

The package is lightweight with zero runtime dependencies and works across Python 3.7 through 3.12 as well as PyPy. It supports both human-readable pretty-printing and compact rendering, handles HTML5 data attributes, provides shortcuts for reserved keywords like `class` and `for`, and allows you to build reusable widget functions using decorators. It's commonly used for server-side HTML generation, dynamic page building, and creating HTML-based reports or documentation.

Use it for

  • Generate HTML pages dynamically in web frameworks without a separate template engine.
  • Build reusable HTML components as decorated Python functions for modular page construction.
  • Create HTML reports or documentation programmatically from Python data structures.
  • Generate email templates or HTML content in backend services without string concatenation.
  • Prototype or test HTML structures in Python without writing raw markup strings.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

Dominate is a mature, actively maintained library with no dependencies, broad Python version support, and no known vulnerabilities. The copyleft license (LGPL-3.0) requires source disclosure if you distribute the library itself, but poses no barrier for internal or open-source use. Install it if you prefer writing HTML in Python over templates or string manipulation.

Install

dominate on PyPI

Before you install

Installation is straightforward with no runtime dependencies. The package is actively maintained with recent commits and a stable release history since 2013, supporting current Python versions (3.7–3.12 and PyPy).

License in practice

Dominate is licensed under LGPL-3.0-or-newer (copyleft). If you distribute software that links or bundles this library, you must make your source code available under compatible terms.

Quickstart

pip install dominate

import dominate
from dominate.tags import div, p, html, body

doc = dominate.document(title='Example')
with doc:
    with div(id='content'):
        p('Hello, World!')

print(doc)

Verify before relying

  • Performance characteristics when generating very large HTML documents or deeply nested structures.
  • Whether the library supports HTML5 semantic elements beyond standard tag coverage.

Package facts

LicenseLGPL-3.0-or-newer copyleft
Python supportSupports the current Python release >=3.4
Install frictionLow. Pure-Python wheel
Runtime dependenciesNone
MaintenanceActively maintained 964 days since the last release
Last repo commit
First released
Downloads2,148,985 / month, #3,253 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Intended Audience :: DevelopersLicense :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)Operating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: PyPyTopic :: Internet :: WWW/HTTP :: Dynamic ContentTopic :: Software Development :: Libraries :: Python ModulesTopic :: Text Processing :: Markup :: HTML

Evidence: dominate-2.9.1-py2.py3-none-any.whl

Tags

Capabilities
python html generationhtml dom apigenerate html in pythonhtml templating without templatespython html builderprogrammatic html creationhtml document generation
Topics
html-generationtemplating-alternative
PyPI keywords
frameworktemplatingtemplatehtmlxhtmlpythonhtml5

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 › “python html generation”

  • dominateDominate is a Python library for writing HTML documents…
  • htpyhtpy lets you write HTML directly in Python using bracket syntax and…
  • MarkupPyMarkupPy generates HTML and XML markup from Python code using an…

Give your agent the search over MCP, or paste the wish link into any chat.

More Python Modules packages

idna Worth it
PyPI · Python Modules · released Jun 2026

Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.

Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.

BSD-3-Clausepure Python · 3.9+
1.8Bdownloads / mo
setuptools Worth it
PyPI · Python Modules · released Aug 2026

Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.

MITpure Python · 3.10+
1.6Bdownloads / mo
PyYAML Worth it
PyPI · Python Modules · released Sep 2025

PyYAML parses and emits YAML 1.1 data format, enabling serialization and deserialization of configuration files and Python objects to and from human-readable YAML text.

MITcompiled wheel · 3.8+
1.2Bdownloads / mo
pydantic Worth it
PyPI · Python Modules · released May 2026

Pydantic validates Python data structures against type hints, coercing and checking input at runtime to ensure it matches a declared schema.

MITpure Python · 3.9+
1.1Bdownloads / mo
annotated-types Worth it
PyPI · Python Modules · released Jul 2026

Provides reusable metadata objects for use with PEP-593 `typing.Annotated` to express common constraints like bounds, collection sizes, and predicates on types.

Install it if you use or build libraries that need to express type constraints in a standardized, inspectable way—or if you want to annotate your own types with…

MITpure Python · 3.10+
871.3Mdownloads / mo
typing-inspection Worth it
PyPI · Python Modules · released Aug 2026

Provides runtime tools to inspect and introspect Python type annotations, enabling programmatic examination of type hints at execution time.

MITpure Python · 3.10+
783.0Mdownloads / mo

See also html5tagger · htmlBuilder · hyperscript · htbuilder · htpy · airium · branca · meld3 · htmltools · braq