prettyprinter
Syntax-highlighting, declarative and composable pretty printer for Python 3.5+
Decision gist · record as of 2026-08-14
Yes, if you are working with Python 3.5 or 3.6 and want better REPL output formatting without dependencies. No, if you need active maintenance or compatibility with modern Python versions—the package is dormant (last release June 2019, no commits since December 2023) and its classifiers suggest it was never updated beyond Python 3.6. Consider it only for legacy projects or as a reference implementation; for new projects, verify that optional extras work with current library versions.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Installation is straightforward with no runtime dependencies.
- However, the package is dormant—last release was 2019-06-22 and no commits since 2023-12-18—so expect no active maintenance or updates for new Python versions or libraries.
License · maintenance · safety
MIT license (permissive) — MIT license (permissive) means you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.
last release 2019-06-22 (2610 days) · last repo commit 2023-12-18 · 341 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 830,388 downloads/mo, #4,949 on PyPI
Alternatives
Verify before relying
pip install prettyprinter
from prettyprinter import pprint
from datetime import datetime
pprint({'output': datetime.now()})- Whether the package remains compatible with Python versions beyond 3.6 despite the classifiers listing only 3.5 and 3.6 support.
- Current state of the optional extras (dataclasses, attrs, django, numpy, requests, pytz) and whether they work with modern versions of those libraries.
- Whether the package is actively maintained or if dormancy signals abandonment.
What it is and what it does
Prettyprinter is a drop-in replacement for Python's standard library pprint that formats data structures with syntax highlighting and readable indentation. It uses a modified Wadler-Leijen layout algorithm to optimize formatting of nested dictionaries, lists, and other common types. The package also provides a declarative interface for registering custom pretty printers for your own classes, so you can define how instances should be displayed without manual string formatting.
The package comes with built-in formatters for datetime, enum, and pytz objects (enabled by default), and optional extras for dataclasses, attrs, django models, numpy arrays, and requests objects. You can install these extras to automatically pretty-print instances of those types. It works by registering type handlers that the printer consults when rendering output, making it easy to extend for domain-specific types.
Use it for
- Replace pprint in REPL sessions and debugging to get syntax-highlighted, readable output for complex nested data structures.
- Register custom pretty printers for your dataclasses or attrs classes to see them formatted nicely in logs and debugging output.
- Pretty-print Django model instances and querysets in development and testing without writing custom __repr__ methods.
- Format numpy arrays and requests library objects with explicit type information for clearer inspection during development.
- Integrate into Jupyter notebooks or IPython shells to improve the readability of cell output for nested or custom objects.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you are working with Python 3.5 or 3.6 and want better REPL output formatting without dependencies.
No, if you need active maintenance or compatibility with modern Python versions—the package is dormant (last release June 2019, no commits since December 2023) and its classifiers suggest it was never updated beyond Python 3.6. Consider it only for legacy projects or as a reference implementation; for new projects, verify that optional extras work with current library versions.
Install
prettyprinter on PyPI
Before you install
Installation is straightforward with no runtime dependencies. However, the package is dormant—last release was 2019-06-22 and no commits since 2023-12-18—so expect no active maintenance or updates for new Python versions or libraries.
License in practice
MIT license (permissive) means you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.
Quickstart
pip install prettyprinter
from prettyprinter import pprint
from datetime import datetime
pprint({'output': datetime.now()})
Verify before relying
- Whether the package remains compatible with Python versions beyond 3.6 despite the classifiers listing only 3.5 and 3.6 support.
- Current state of the optional extras (dataclasses, attrs, django, numpy, requests, pytz) and whether they work with modern versions of those libraries.
- Whether the package is actively maintained or if dormancy signals abandonment.
Package facts
| License | MIT license permissive |
| Python support | Not specified |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Dormant 2,610 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 830,388 / month, #4,949 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 2 - Pre-AlphaIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseNatural Language :: EnglishProgramming Language :: Python :: 3.5Programming Language :: Python :: 3.6 |
Evidence: prettyprinter-0.18.0-py2.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 › “pretty print python objects”
- prettyprinterSyntax-highlighted, declarative pretty printer for Python that…
- wadler-lindigFormats Python objects for readable output using the Wadler–Lindig…
- sqlalchemy-reprAdds automatic, human-readable repr() output to SQLAlchemy model…
Give your agent the search over MCP, or paste the wish link into any chat.
More Utilities packages
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.
Detects and normalizes text encoding from unknown or ambiguous sources, supporting all IANA character sets that Python's core library provides codecs for, with the ability to register custom codecs.
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.
Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.
Install it if you're building an extensible application or framework.
Pygments is a syntax highlighter that colorizes source code and text in over 500 languages and formats, outputting to HTML, LaTeX, RTF, SVG, images, or ANSI terminal sequences.
Install it if you need to display or transform source code.
Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.
See also gdbmongo · python-printr · wadler-lindig · pprintpp · treescope · pycups · structlog-pretty · wasabi · django-rich · better-exceptions