# Install pgcli with Homebrew, apk, apt, dnf, MacPorts, Nix, pacman

CLI for Postgres with auto-completion and syntax highlighting. Version 4.5.0 via Homebrew; verified 2026-06-22.

## Install

```sh
sudo av install brew:pgcli
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install pgcli
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install pgcli
```

  Evidence: MacPorts ports tree: databases/pgcli/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add pgcli
```

  Evidence: Alpine Linux edge package indexes: pgcli from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install pgcli
```

  Evidence: Debian stable package indexes: pgcli from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install pgcli
```

  Evidence: Fedora Rawhide package metadata: pgcli from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#pgcli
```

  Evidence: nixpkgs package indexes: pgcli from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix

- pacman (92%):

```sh
sudo pacman -S pgcli
```

  Evidence: Arch Linux sync databases: pgcli from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

## Package facts

- **Package key:** brew:pgcli
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/pgcli>
- **Version:** 4.5.0
- **Source summary:** CLI for Postgres with auto-completion and syntax highlighting
- **Homepage:** <https://pgcli.com/>
- **Repository:** <https://github.com/dbcli/pgcli>
- **Upstream docs:** <https://github.com/dbcli/pgcli/blob/main/README.rst>
- **License:** BSD-3-Clause
- **Source archive:** <https://files.pythonhosted.org/packages/e0/ca/b081f0ae381425f87dd751b449c33aca7398c2183799fc56501fe7c26975/pgcli-4.5.0.tar.gz>
- **Last updated:** 2026-06-22T14:05:52-07:00
- **Generated:** 2026-07-09T07:20:21+00:00

## Executables

- pgcli (cli)
- pgcli (alias)

## Dependencies

- libpq
- python@3.14

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-09
- Package-manager version: 4.5.0
- Package-manager updated: 2026-06-22
- Local data: ok
- Upstream repository: https://pgcli.com/
- info: Release/tag comparison is only available for GitHub repositories.

## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ~/.config/pgcli/config
## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** pgcli
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## Other Package-Manager Records

- Debian apt - pgcli - 4.3.0-2: normalized package name match | Debian stable package indexes: pgcli from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | CLI for PostgreSQL with auto-completion and syntax highlighting | https://www.pgcli.com
- Nix - pgcli: normalized package name match | nixpkgs package indexes: pgcli from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix
- Ubuntu apt - pgcli - 4.0.1-1: normalized package name match | Ubuntu 24.04 LTS package indexes: pgcli from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | CLI for PostgreSQL with auto-completion and syntax highlighting | https://www.pgcli.com
- apk - pgcli - 4.5.0-r0: normalized package name match | Alpine Linux edge package indexes: pgcli from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Postgres CLI with autocompletion and syntax highlighting | https://www.pgcli.com
- apk - pgcli-pyc - 4.5.0-r0: normalized package name match | Alpine Linux edge package indexes: pgcli-pyc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Precompiled Python bytecode for pgcli | https://www.pgcli.com
- dnf - pgcli - 4.5.0-2.fc45: normalized package name match | Fedora Rawhide package metadata: pgcli from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | CLI for Postgres Database. With auto-completion and syntax highlighting | https://www.pgcli.com/
- dnf - python3-pgcli+keyring - 4.5.0-2.fc45: normalized package name match | Fedora Rawhide package metadata: python3-pgcli+keyring from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | Metapackage for python3-pgcli: keyring extras | https://www.pgcli.com/
- dnf - python3-pgcli+sshtunnel - 4.5.0-2.fc45: normalized package name match | Fedora Rawhide package metadata: python3-pgcli+sshtunnel from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | Metapackage for python3-pgcli: sshtunnel extras | https://www.pgcli.com/
- pacman - pgcli - 4.5.0-1: normalized package name match | Arch Linux sync databases: pgcli from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A command line interface for PostgreSQL with auto-completion and syntax highlighting | https://www.pgcli.com/
- MacPorts - pgcli: normalized package name match | MacPorts ports tree: databases/pgcli/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Related links

- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [libpq](https://www.automicvault.com/pkg/brew/libpq/) - Runtime dependency declared by Homebrew.
- [python@3.14](https://www.automicvault.com/pkg/brew/python-3-14/) - Runtime dependency declared by Homebrew.
- [litecli](https://www.automicvault.com/pkg/brew/litecli/) - Shares av.db curated category or tags: autocomplete, cli, database, database-client, developer-tools.
- [pg-schema-diff](https://www.automicvault.com/pkg/brew/pg-schema-diff/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pg_partman](https://www.automicvault.com/pkg/brew/pg-partman/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pg_top](https://www.automicvault.com/pkg/brew/pg-top/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pgbackrest](https://www.automicvault.com/pkg/brew/pgbackrest/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pgbadger](https://www.automicvault.com/pkg/brew/pgbadger/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pgbouncer](https://www.automicvault.com/pkg/brew/pgbouncer/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pgcopydb](https://www.automicvault.com/pkg/brew/pgcopydb/) - Shares av.db curated category or tags: cli, database, developer-tools, postgresql.
- [pgcli](https://www.automicvault.com/pkg/pip/pgcli/) - Same normalized package name appears in another local ecosystem. Shared terms: auto, auto-completion, completion, database, highlighting.
- [harlequin](https://www.automicvault.com/pkg/brew/harlequin/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, client, database, database-client, developer.
- [pgcli](https://www.automicvault.com/pkg/pip/pgcli/) - Same normalized package name in another local ecosystem.

## Combined YAML source

View the package source record on GitHub. [combined/pgcli.yml](https://github.com/automic-vault/db/blob/main/combined/pgcli.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
