Skip to main content
uv pip uninstall removes packages from the active Python environment. It is compatible with pip uninstall but offers faster performance.

Usage

Arguments

package
string[]
required
Names of packages to uninstall.
-r, --requirements
path[]
Uninstall packages listed in requirements files.Supported formats:
  • requirements.txt
  • .py files with inline metadata
  • pylock.toml
  • pyproject.toml, setup.py, setup.cfg

Python Environment

-p, --python
string
Python interpreter from which to uninstall packages.By default, uninstalls from virtual environment. Use with caution for system Python.
Environment: UV_PYTHON
--system
Uninstall from system Python instead of virtual environment.
Use with caution in CI environments only. Can modify system Python installation.
Environment: UV_SYSTEM_PYTHON
--break-system-packages
Allow uninstallation from externally-managed Python environments.
Intended for CI environments. Use with caution.
Environment: UV_BREAK_SYSTEM_PACKAGES
-t, --target
path
Uninstall packages from a --target directory.
--prefix
path
Uninstall packages from a --prefix directory.

Behavior Options

--dry-run
Show what would be uninstalled without actually removing packages.
--keyring-provider
string
Keyring provider for authentication (for remote requirements files): disabled, subprocess.Default: disabledEnvironment: UV_KEYRING_PROVIDER

Examples

Basic Uninstallation

From Requirements File

Specific Environment

Dry Run

Use Cases

Remove Unwanted Packages

Clean Development Environment

Fix Broken Installation

Downgrade Package

Verify Before Uninstall

Differences from pip uninstall

uv pip uninstall is largely compatible with pip uninstall:

Key Differences

  1. Performance: uv is faster
  2. Confirmation: uv does not prompt for confirmation (use --dry-run first)
  3. Default behavior: uv requires virtual environment by default
  4. Dependency handling: Both only remove specified packages, not their dependencies

No Confirmation Prompt

Unlike pip, uv does not ask for confirmation:

Migration from pip

Handling Dependencies

uv pip uninstall only removes specified packages, not their dependencies:

Remove Package and Dependencies

To remove orphaned dependencies:

What Gets Uninstalled

Regular Packages

Editable Packages

Scripts and Entry Points

Exit Codes

Safety Considerations

Check Dependencies First

Use Dry Run

Avoid System Python