# pgcli

> BSD-3-Clause Postgres CLI with smart autocompletion

**Category:** Databases  
**Pricing:** open-source  
**URL:** https://www.pgcli.com  
**GitHub:** https://github.com/dbcli/pgcli  
**Added:** 2026-10-18

---

## The Hook

pgcli is a drop-in replacement for psql with smart autocompletion of tables, columns and keywords, syntax highlighting and nicer output — the terminal Postgres client you actually enjoy using.

## What's Good

BSD-3-Clause (dbcli/pgcli), release v4.7.1 (2026-09-20), maintained since 2014. Install with pip, apt or brew, then connect with the same arguments as psql. It is context-aware (suggests columns from the tables in your FROM clause), supports most backslash commands, named queries, pagers, multi-line editing and vi/emacs keys. Sibling project mycli does the same for MySQL. ★~13.4k.

## The Catch

It is a Python app, so startup is slower than psql and you need a Python environment. Some psql meta-commands and scripting behaviours differ, so keep psql for scripts. Huge schemas can make the completion refresh slow.

## Verdict

Install it once and you will stop using bare psql for interactive work.
