Skip to content
Latchkey

pip list: Inspect Installed Packages

See exactly what is installed in this environment.

pip list prints installed packages and their versions. It is a quick way to confirm what a CI environment actually resolved to.

What it does

Lists every installed distribution and its version. Flags filter to outdated packages or change the output format for machine parsing.

Common usage

Terminal
pip list
pip list --outdated
pip list --format=freeze
pip list --format=json

Common CI gotcha: parsing the table

The default human-readable table has a header row and underlines, which break naive grep/awk parsing. Use --format=freeze or --format=json when a script consumes the output.

Terminal
# Brittle:
# pip list | grep requests   # also matches headers/extra rows

# Robust:
pip list --format=json

Options

OptionDoes
-o, --outdatedShow only outdated packages
--format FORMATcolumns, freeze, or json
--userList packages in the user site
--not-requiredList packages no other depends on

Related guides

Run this faster and cheaper on Latchkey managed runners. Start free →