tcolorpy
tcolopy is a Python library to apply true color for terminal text.
What it is and what it does
tcolorpy is a lightweight Python library for styling terminal text with true color and text effects. It wraps ANSI escape sequences, allowing you to colorize and format output using either hex color codes (like "#ee1177") or standard color names ("red", "green", etc.), combined with styles such as bold, italic, underline, and others.
The library has no external dependencies and works as both a Python module and a command-line tool. You import the tcolor function, pass a string along with color and style arguments, and get back a formatted string ready to print. It's designed for developers who want to add visual emphasis to terminal output without manually constructing ANSI escape codes.
Use it for:
- Colorize log output or status messages in CLI applications with semantic colors (red for errors, green for success).
- Add visual emphasis to terminal-based progress indicators, warnings, or debug output.
- Build styled help text or command-line interfaces with consistent color and formatting rules.
- Generate colored terminal output in scripts for better readability and user experience.
- Apply multiple text styles (bold + underline + color) to highlight important information in terminal output.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Applies ANSI true color and text styles (bold, italic, underline, etc.) to terminal output using hex color codes or named colors.
Yes. tcolorpy is a low-friction, dependency-free utility for terminal styling with active maintenance, no known vulnerabilities, and permissive licensing. Install it if you need to add true color and text effects to terminal output; skip it if your application doesn't interact with terminals or if you're already using a larger terminal UI framework.
Install
tcolorpy on PyPI
pip
pip install tcolorpyuv
uv add tcolorpypoetry
poetry add tcolorpyInstalling tcolorpy
Before you install
Low friction: pure Python wheel with no external dependencies and active maintenance (last commit 2026-04-13). Supports Python 3.9+ across CPython and PyPy.
License in practice
MIT License permits unrestricted use, modification, and distribution with minimal obligations—suitable for commercial and private projects.
Quickstart
pip install tcolorpy
from tcolorpy import tcolor
print(tcolor("Hello", color="#ee1177", styles=["bold", "italic"]))
Requires Python 3.9 or later.
Verify before relying
- Whether terminal support for true color is automatically detected or requires manual configuration.
- Behavior on terminals that do not support true color or ANSI escape sequences.
Package facts
| License | MIT License (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 593 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 2,869,211/month — #2,851 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: tcolorpy-0.1.7-py3-none-any.whl
Keywords: ANSI escape, terminal color, truecolor
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
simple-colorsAdds colored and styled text output to terminal…
unclear · top 15,000 on PyPI
termcolorAdds ANSI color and text formatting (bold,…
permissive · top 1,000 on PyPI
ansicolorsEmbeds ANSI color and style codes into Python…
permissive · top 5,000 on PyPI
styleApplies ANSI color and text styling to terminal…
permissive · top 15,000 on PyPI
colorfulColorful applies ANSI color and text styling to…
permissive · top 5,000 on PyPI
pastelPastel adds colored text output to terminal…
permissive · top 5,000 on PyPI
crayonsCrayons provides colored text output for…
permissive · top 15,000 on PyPI
coloredColored provides ANSI/VT100 escape sequences…
permissive · top 5,000 on PyPI
ascii-colorsUnified terminal UI library providing colored…
permissive · top 15,000 on PyPI
stySty provides a simple, customizable string…
permissive · top 15,000 on PyPI