pipx

pipx installs and runs end-user Python applications in isolated environments. It fills the same role as macOS’s brew, JavaScript’s npx, and Linux’s apt. Under the hood it uses pip, but unlike pip it creates a separate virtual environment for each application, so their dependencies never collide and an uninstall leaves nothing behind.

        flowchart LR
    USER["you"] -->|"pipx install"| PIPX["pipx"]
    USER -->|"pipx run"| PIPX
    PIPX -->|"fetches from"| PYPI["PyPI"]
    PIPX -->|"creates"| VENV["isolated venvs"]
    VENV -->|"exposes on PATH"| APPS["black, ruff,<br/>poetry, ..."]

    classDef you fill:#3f72af,stroke:#28507d,color:#fff;
    classDef pipx fill:#2a9d8f,stroke:#1f7268,color:#fff;
    classDef src fill:#c78c20,stroke:#946716,color:#fff;
    classDef venv fill:#7c4dff,stroke:#5a34c0,color:#fff;
    classDef apps fill:#388e3c,stroke:#276628,color:#fff;
    class USER you;
    class PIPX pipx;
    class PYPI src;
    class VENV venv;
    class APPS apps;
    

Start here

Tutorials

Install your first application and run one in a throwaway environment, one step at a time.

Tutorials
How-to guides

Task recipes for installing pipx, injecting packages, pinning versions, configuring paths, and more.

How-to guides
Reference

The full CLI, environment variables, exit codes, the JSON envelope, and worked examples.

Reference
Explanation

How pipx works, what it manages on disk, and how it compares to other tools.

Explanation

pip vs pipx

pip installs both libraries and applications into whatever environment is active, with no isolation. pipx installs only applications, each in its own virtual environment, and exposes their commands on your PATH. You get clean uninstalls, zero dependency conflicts between tools, and no sudo pip install — pipx runs with regular user permissions.

Where apps come from

pipx pulls packages from PyPI by default, but accepts any source pip supports: local directories, wheels, and git URLs. Any package that declares console script entry points works with pipx. Poetry and Hatch users can add entry points the same way.

Highlights

  • Install CLI apps into isolated environments with pipx install, so there are no dependency conflicts and uninstalls are clean.

  • List, upgrade, and uninstall managed apps in one command.

  • Run the latest version of any app in a temporary environment with pipx run, without installing it first.

Testimonials

“Thanks for improving the workflow that pipsi has covered in the past. Nicely done!”

Jannis Leidel, PSF fellow, former pip and Django core developer, and founder of the Python Packaging Authority (PyPA)

“My setup pieces together pyenv, poetry, and pipx. […] For the things I need, it’s perfect.”

Jacob Kaplan-Moss, co-creator of Django, in My Python Development Environment, 2020 Edition

“I’m a big fan of pipx. I think pipx is super cool.”

Michael Kennedy, co-host of the PythonBytes podcast, in episode 139

Credits

pipx was inspired by pipsi and npx. It was created by Chad Smith and has had lots of help from contributors. The logo was created by @IrishMorales.

pipx is maintained by a team of volunteers (in alphabetical order):

Emeritus maintainers, who shaped earlier releases:

The documentation follows the Diátaxis framework.