> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.com/astral-sh/uv/llms.txt
> Use this file to discover all available pages before exploring further.

# uv pip list

> List installed packages in table format.

`uv pip list` displays installed packages in a human-readable format. It is similar to `pip list` but offers additional output formats and faster performance.

## Usage

```bash theme={null}
# List all packages
uv pip list

# List in JSON format
uv pip list --format json

# List outdated packages
uv pip list --outdated

# List editable packages only
uv pip list --editable
```

## Arguments

### Filtering Options

<ParamField body="-e, --editable">
  Show only editable packages.

  ```bash theme={null}
  uv pip list --editable
  ```
</ParamField>

<ParamField body="--exclude-editable">
  Exclude editable packages from output.

  ```bash theme={null}
  uv pip list --exclude-editable
  ```
</ParamField>

<ParamField body="--exclude" type="package[]">
  Exclude specific packages from output.

  ```bash theme={null}
  uv pip list --exclude setuptools --exclude wheel
  ```
</ParamField>

<ParamField body="--outdated">
  List outdated packages with available updates.

  Shows both installed and latest versions.

  ```bash theme={null}
  uv pip list --outdated
  ```
</ParamField>

### Output Format

<ParamField body="--format" type="string">
  Output format: `columns`, `freeze`, or `json`.

  * `columns`: Human-readable table (default)
  * `freeze`: pip freeze format
  * `json`: Machine-readable JSON

  Default: `columns`

  ```bash theme={null}
  uv pip list --format json
  uv pip list --format freeze
  ```
</ParamField>

### Python Environment

<ParamField body="-p, --python" type="string">
  Python interpreter from which to list packages.

  By default, lists from virtual environment or system Python if no venv is found.

  ```bash theme={null}
  uv pip list --python 3.11
  uv pip list --python /path/to/python
  ```

  Environment: `UV_PYTHON`
</ParamField>

<ParamField body="--system">
  List packages from system Python, ignoring virtual environments.

  ```bash theme={null}
  uv pip list --system
  ```

  Environment: `UV_SYSTEM_PYTHON`
</ParamField>

<ParamField body="-t, --target" type="path">
  List packages from a `--target` directory.

  ```bash theme={null}
  uv pip list --target ./libs
  ```
</ParamField>

<ParamField body="--prefix" type="path">
  List packages from a `--prefix` directory.

  ```bash theme={null}
  uv pip list --prefix /opt/myapp
  ```
</ParamField>

### Validation

<ParamField body="--strict">
  Validate the environment, detecting packages with missing dependencies.

  ```bash theme={null}
  uv pip list --strict
  ```
</ParamField>

### Index Options

<ParamField body="--index" type="url[]">
  Package indexes to check for updates (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --index https://pypi.org/simple
  ```

  Environment: `UV_INDEX`
</ParamField>

<ParamField body="--default-index" type="url">
  Default package index (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --default-index https://private.pypi.org/simple
  ```

  Environment: `UV_DEFAULT_INDEX`
</ParamField>

<ParamField body="-i, --index-url" type="url">
  Deprecated: Use `--default-index` instead.

  Environment: `UV_INDEX_URL`
</ParamField>

<ParamField body="--extra-index-url" type="url[]">
  Deprecated: Use `--index` instead.

  Environment: `UV_EXTRA_INDEX_URL`
</ParamField>

<ParamField body="-f, --find-links" type="path|url[]">
  Additional locations to search for packages (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --find-links ./wheels
  ```

  Environment: `UV_FIND_LINKS`
</ParamField>

<ParamField body="--no-index">
  Ignore package indexes (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --no-index --find-links ./wheels
  ```
</ParamField>

<ParamField body="--index-strategy" type="string">
  Index selection strategy: `first-index`, `unsafe-first-match`, or `unsafe-best-match`.

  Default: `first-index`

  Environment: `UV_INDEX_STRATEGY`
</ParamField>

<ParamField body="--keyring-provider" type="string">
  Keyring provider for authentication: `disabled`, `subprocess`.

  Default: `disabled`

  Environment: `UV_KEYRING_PROVIDER`
</ParamField>

### Version Constraints

<ParamField body="--exclude-newer" type="date">
  Exclude packages uploaded after the specified date (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --exclude-newer 2024-01-01
  ```

  Environment: `UV_EXCLUDE_NEWER`
</ParamField>

<ParamField body="--exclude-newer-package" type="package=date[]">
  Exclude specific packages uploaded after dates (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --exclude-newer-package "numpy=2024-01-01"
  ```
</ParamField>

<ParamField body="--prerelease" type="string">
  Pre-release handling (for `--outdated`): `disallow`, `allow`, `if-necessary`, `explicit`, or `if-necessary-or-explicit`.

  Default: `if-necessary-or-explicit`

  Environment: `UV_PRERELEASE`
</ParamField>

### Cache Options

<ParamField body="--refresh">
  Refresh all cached data (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --refresh
  ```
</ParamField>

<ParamField body="--refresh-package" type="package[]">
  Refresh cached data for specific packages (for `--outdated`).

  ```bash theme={null}
  uv pip list --outdated --refresh-package numpy
  ```
</ParamField>

## Output Formats

### Columns (Default)

Human-readable table format:

```txt theme={null}
Package               Version
--------------------- ---------
certifi               2024.2.2
charset-normalizer    3.3.2
idna                  3.6
requests              2.31.0
urllib3               2.2.1
```

### Freeze Format

Same as `uv pip freeze`:

```txt theme={null}
certifi==2024.2.2
charset-normalizer==3.3.2
idna==3.6
requests==2.31.0
urllib3==2.2.1
```

### JSON Format

Machine-readable JSON:

```json theme={null}
[
  {
    "name": "certifi",
    "version": "2024.2.2"
  },
  {
    "name": "charset-normalizer",
    "version": "3.3.2"
  },
  {
    "name": "requests",
    "version": "2.31.0",
    "editable_project_location": "/path/to/requests"
  }
]
```

### Outdated Format

With `--outdated`, shows available updates:

```txt theme={null}
Package     Version  Latest   Type
----------- -------- -------- -----
requests    2.30.0   2.31.0   wheel
numpy       1.24.0   1.26.0   wheel
```

## Examples

### Basic Usage

```bash theme={null}
# List all packages
uv pip list

# List with line numbers
uv pip list | nl

# Count packages
uv pip list --format freeze | wc -l
```

### Filter Output

```bash theme={null}
# Show only editable packages
uv pip list --editable

# Exclude editable packages
uv pip list --exclude-editable

# Exclude specific packages
uv pip list --exclude pip --exclude setuptools
```

### Different Formats

```bash theme={null}
# Human-readable table
uv pip list

# Freeze format
uv pip list --format freeze

# JSON format
uv pip list --format json

# Pretty-print JSON
uv pip list --format json | jq
```

### Check for Updates

```bash theme={null}
# List outdated packages
uv pip list --outdated

# Outdated in JSON
uv pip list --outdated --format json

# With custom index
uv pip list --outdated --index https://private.pypi.org/simple
```

### Specific Environment

```bash theme={null}
# From specific Python
uv pip list --python 3.11

# From system Python
uv pip list --system

# From target directory
uv pip list --target ./libs
```

### Process with Tools

```bash theme={null}
# Search for package
uv pip list --format freeze | grep requests

# Export to JSON file
uv pip list --format json > packages.json

# Count outdated packages
uv pip list --outdated --format freeze | wc -l

# Check for specific outdated package
uv pip list --outdated --format freeze | grep numpy
```

## Use Cases

### Audit Installed Packages

```bash theme={null}
# View all packages
uv pip list

# Check for outdated dependencies
uv pip list --outdated
```

### Generate Reports

```bash theme={null}
# JSON report for tooling
uv pip list --format json > packages.json

# Freeze format for requirements
uv pip list --format freeze > requirements.txt
```

### Compare Environments

```bash theme={null}
# Export both environments
uv pip list --format json > local.json
uv pip list --python /path/to/prod/python --format json > prod.json

# Compare with jq
jq -s '.[0] - .[1]' local.json prod.json
```

### CI/CD Health Checks

```bash theme={null}
# Check for outdated packages in CI
if uv pip list --outdated --format freeze | grep -q .; then
  echo "Outdated packages found"
  uv pip list --outdated
fi
```

### Find Development Packages

```bash theme={null}
# List editable installs (usually dev packages)
uv pip list --editable
```

## Differences from pip list

`uv pip list` is largely compatible with `pip list`:

```bash theme={null}
# pip command
pip list

# Equivalent uv command
uv pip list
```

### Key Differences

1. **Performance**: uv is faster, especially for `--outdated`
2. **Default format**: Both use columns by default
3. **JSON schema**: Slightly different structure
4. **Index options**: uv uses `--index` instead of `--extra-index-url`

### Unsupported pip Options

Most pip list options are supported. Notable exceptions:

* `--uptodate`: Not implemented (inverse of `--outdated`)
* `--user`: Use `--system` or virtual environments
* Some legacy pip list behaviors

## Comparison with uv pip freeze

| Feature        | `uv pip list`         | `uv pip freeze`       |
| -------------- | --------------------- | --------------------- |
| Default format | Table (columns)       | requirements.txt      |
| Formats        | columns, freeze, json | Text only             |
| Use case       | Viewing/inspection    | Reproducible installs |
| Outdated check | Yes                   | No                    |
| Editables      | Shows installed       | Shows source paths    |

```bash theme={null}
# For viewing
uv pip list

# For requirements files
uv pip freeze > requirements.txt

# List can also output freeze format
uv pip list --format freeze > requirements.txt
```

## Related Commands

* [`uv pip freeze`](/cli/pip-freeze) - Output in requirements format
* [`uv pip show`](/cli/pip-show) - Show package details
* [`uv pip install`](/cli/pip-install) - Install packages
