Pipenv combines pip, virtualenv, and project manifests to manage isolated Python environments. Linux, macOS, and Windows are supported.
Overview
Pipenv is a command-line tool for Python projects that manages virtual environments and package dependencies in one workflow. It bridges pip, Python interpreters from the system or tools like pyenv and asdf, and virtualenv-style isolation.
When you install or remove packages, it updates a Pipfile and can generate a Pipfile.lock for reproducible environments. Locked installs can verify package hashes recorded in the lock file.
The tool discovers project roots by locating a Pipfile, creates a virtualenv in a standard location when needed, and can load .env files for local settings. Commands expose dependency graphs, security checks, shells inside the env, and separate dev dependency groups.
It is meant to replace juggling pip, virtualenv, and hand-maintained requirements files with a single interface oriented around per-project environments and clearer dependency metadata.
Key features
- Pipfile and lockfile workflow
- Automatic virtualenv creation
- Hash-verified locked installs
- Dependency graph command
- Dev and default package groups
- Automatic .env file loading
- pyenv and asdf Python selection
- VCS URL package installs
Use cases
- Isolated Python application development
- Reproducible team environments
- Tracking dev versus prod packages
- Auditing dependency relationships
- Replacing manual requirements files