Rich

Beautiful terminal text formatting library for Python. Renders rich text with markup, tables, syntax-highlighted code, progress bars, spinners, trees, panels, and live-updating displays. Created by Will McGuire (Textualize). Used by pip, Ansible, and hundreds of popular Python CLI tools. Automatic color detection and graceful degradation in non-color terminals.

Evaluated Mar 06, 2026 (0d ago) v13.x
Homepage ↗ Repo ↗ Developer Tools rich python terminal formatting tables syntax-highlighting progress logging
⚙ Agent Friendliness
71
/ 100
Can an agent use this?
🔒 Security
96
/ 100
Is it safe for agents?
⚡ Reliability
92
/ 100
Does it work consistently?

Score Breakdown

⚙ Agent Friendliness

MCP Quality
--
Documentation
95
Error Messages
88
Auth Simplicity
100
Rate Limits
100

🔒 Security

TLS Enforcement
100
Auth Strength
100
Scope Granularity
100
Dep. Hygiene
88
Secret Handling
90

MIT licensed. Terminal output only — no network. Avoid logging sensitive data through Rich's handlers in production.

⚡ Reliability

Uptime/SLA
100
Version Stability
90
Breaking Changes
88
Error Recovery
92
AF Security Reliability

Best When

You're building a Python CLI tool or developer tool and want beautiful, readable terminal output with minimal effort.

Avoid When

You need interactive terminal input (forms, menus) — use Textual or prompt_toolkit. For production logging, use loguru or structlog.

Use Cases

  • Display agent progress with rich progress bars showing task status, ETA, and completion percentage
  • Format agent output with syntax-highlighted JSON/code, colored tables, and styled panels
  • Add structured logging with Rich's RichHandler for colorized, indented log output in agent development
  • Build interactive agent TUI layouts with Rich's Live display for real-time updating dashboards
  • Pretty-print agent data structures with rich.inspect() for debugging and development

Not For

  • Full TUI applications requiring keyboard input — use Textual (also by Textualize) for interactive TUI with input widgets
  • Browser output — Rich outputs ANSI terminal codes; not compatible with HTML rendering
  • High-throughput logging in production — Rich's formatting has overhead; use structlog or loguru for production structured logging

Interface

REST API
No
GraphQL
No
gRPC
No
MCP Server
No
SDK
Yes
Webhooks
No

Authentication

Methods: none
OAuth: No Scopes: No

Local library — no authentication required. MIT licensed.

Pricing

Model: open_source
Free tier: Yes
Requires CC: No

MIT licensed. Zero cost.

Agent Metadata

Pagination
none
Idempotent
Full
Retry Guidance
Not documented

Known Gotchas

  • from rich import print overrides Python's built-in print — this is intentional and transparent but can surprise when debugging with basic print() calls
  • Rich markup uses [bold], [green], [link=url] syntax — if your content contains square brackets, escape them: '\[literal bracket]' or use highlight=False
  • Console(file=sys.stderr) for stderr output — default Console writes to stdout; use stderr for logging to separate from data output
  • Progress bars must be used as context managers: with Progress() as progress: task = progress.add_task('...') — calling progress.update() outside context doesn't display
  • Live display updates: with Live(renderable, refresh_per_second=4) as live: — use live.update(new_renderable) to update; high refresh rates increase CPU usage
  • Console() captures=False by default — set Console(record=True) then console.export_text() or export_html() for capturing output programmatically

Alternatives

Full Evaluation Report

Detailed scoring breakdown, competitive positioning, security analysis, and improvement recommendations for Rich.

$99

Scores are editorial opinions as of 2026-03-06.

5208
Packages Evaluated
26151
Need Evaluation
173
Need Re-evaluation
Community Powered