prettierfier
Intelligently pretty-print HTML/XML with inline tags.
Decision gist · record as of 2026-08-14
No. The project is abandoned with its last release on 2019-07-22 and no maintenance since. While the code is simple and dependency-free, there is no path to bug fixes or compatibility updates. For active alternatives, consider using BeautifulSoup with a custom formatter or modern HTML/XML libraries with maintained prettification support.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Installation is frictionless—the package has no external dependencies and installs as a pure Python wheel.
- However, the project has been abandoned since its last release on 2019-07-22 with no updates since, so expect no maintenance or bug fixes going forward.
License · maintenance · safety
MIT (permissive) — Licensed under MIT (permissive), so you can use, modify, and distribute this package freely in both open-source and commercial projects with minimal restrictions.
last release 2019-07-22 (2580 days) · last repo commit 2019-07-22 · 5 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 614,995 downloads/mo, #5,744 on PyPI
Alternatives
Verify before relying
pip install prettierfier
import prettierfier
ugly_html = """<span>Introducing GitHub</span><sup>®</sup>"""
pretty = prettierfier.prettify_html(ugly_html)
print(pretty)- Whether the regex-based parsing handles all HTML5/XML edge cases or only a subset of real-world markup.
- Performance characteristics on large documents or whether there are known scalability limits.
- Compatibility with Python versions beyond 3.7 (the latest classifier listed), given the maintenance gap.
What it is and what it does
Prettierfier is a lightweight HTML and XML formatter that solves a specific problem: BeautifulSoup's prettify() method adds line breaks between every tag, which breaks inline elements like `<span>`, `<sup>`, and `<em>`. This package uses regex-based parsing to reformat markup more intelligently, preserving inline tags on the same line while still indenting block-level structure.
The package contains no external dependencies—it uses only the Python Standard Library—and offers two main functions: prettify_xml() for raw XML with configurable indentation, and prettify_html() designed to post-process BeautifulSoup output. It's a single-purpose tool for developers who need cleaner, more readable HTML/XML output without the whitespace bloat.
Use it for
- Post-process BeautifulSoup.prettify() output to remove unwanted line breaks between inline HTML tags.
- Format raw XML strings with intelligent indentation before writing to files or logs.
- Clean up HTML templates or scraped markup for human readability without breaking inline element layout.
- Debug HTML/XML structure by viewing it in a more compact, readable form than standard prettifiers produce.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
No.
The project is abandoned with its last release on 2019-07-22 and no maintenance since. While the code is simple and dependency-free, there is no path to bug fixes or compatibility updates. For active alternatives, consider using BeautifulSoup with a custom formatter or modern HTML/XML libraries with maintained prettification support.
Install
prettierfier on PyPI
Before you install
Installation is frictionless—the package has no external dependencies and installs as a pure Python wheel. However, the project has been abandoned since its last release on 2019-07-22 with no updates since, so expect no maintenance or bug fixes going forward.
License in practice
Licensed under MIT (permissive), so you can use, modify, and distribute this package freely in both open-source and commercial projects with minimal restrictions.
Quickstart
pip install prettierfier
import prettierfier
ugly_html = """<span>Introducing GitHub</span><sup>®</sup>"""
pretty = prettierfier.prettify_html(ugly_html)
print(pretty)
Verify before relying
- Whether the regex-based parsing handles all HTML5/XML edge cases or only a subset of real-world markup.
- Performance characteristics on large documents or whether there are known scalability limits.
- Compatibility with Python versions beyond 3.7 (the latest classifier listed), given the maintenance gap.
Package facts
| License | MIT permissive |
| Python support | Not specified |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Abandoned 2,580 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 614,995 / month, #5,744 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Intended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseNatural Language :: EnglishOperating System :: Microsoft :: WindowsProgramming Language :: Python :: 3Programming Language :: Python :: 3.7Topic :: Text Processing :: Markup :: HTMLTopic :: Text Processing :: Markup :: XML |
Evidence: prettierfier-1.0.3-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 › “html xml formatting”
- prettierfierReformats HTML and XML strings with intelligent inline-tag handling,…
- MarkupSafeMarkupSafe provides a text object that escapes special characters so…
- pybtexPybtex reads bibliography data from BibTeX, BibTeXML, or YAML files…
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 BeautifulSoup · xmlformatter · MarkupPy · pynliner · markdownify · premailer · html-to-json · html-sanitizer · dmiparser