Skip to content

Pipenv

A tool that manages a Python project's virtual environment and dependencies in one place.

Stars
25k
Forks
1.9k
Licence
MIT
Language
Python
Last update
4 days ago
Type
Dev tool

What it is

Pipenv is a command-line tool for Python projects that creates and manages a virtual environment for each project and tracks its packages in a Pipfile. When you install or remove a package, it updates the Pipfile automatically and writes a Pipfile.lock so that other people or machines can recreate the same set of versions. It is meant to combine pip and virtualenv into a single workflow.

  • Create a project virtualenv for a specific Python version with pipenv --python 3.7
  • Install packages and have them recorded in the Pipfile automatically with pipenv install
  • Generate a lock file with pipenv lock and install exactly those versions with pipenv sync
  • Check installed dependencies for known security vulnerabilities with pipenv check
  • View the dependency tree with pipenv graph

Great for

  • Python application developers who want one command set for environments and dependencies
  • Teams that want reproducible installs from a lock file with hash checking
  • People moving away from manually maintained requirements.txt files
  • Developers working across Linux, macOS, and Windows

Not ideal for

  • Users who already have a working workflow with pip-tools or Poetry and no reason to switch, since the README does not compare these tools
  • Projects that are not Python, because the tool only manages Python environments
  • Anyone needing a tool that runs on a system without Python 3.10 or newer, since the README states that is the minimum for installing Pipenv
Step-by-step guide: how to use PipenvInstall, first run, examples, tips and FAQs

How to get it

  1. 1

    Install with a package manager

    You'll need: Python 3.10 or above · pip

    Install with pip (recommended for most users)

    pip install --user pipenv

    Alternative install with pipx

    pipx install pipenv
  2. 2

    Run it

    • Install Pipenv with pip or pipx as shown above
    • Go to your project folder and run pipenv install to create a virtualenv and Pipfile
    • Add a package with pipenv install <package-name>
    • Run your code with pipenv run python <script>, or open a shell with pipenv shell
  3. 3

    Get the most out of it

    • Use pipenv install --dev to separate development-only dependencies from application ones
    • Run pipenv lock --pre if you need to include pre-release versions in the lock file
    • Put local settings in a .env file, since Pipenv loads these automatically
    • Set up shell completion for bash, zsh, or fish using register-python-argcomplete as described in the README
    • Use pipenv check to scan for security vulnerabilities in your installed packages

Downloads

Strengths

  • Keeps package declarations and exact locked versions in separate files with hash verification
  • Handles the virtualenv lifecycle so users do not need to activate or manage it manually for most tasks
  • The README states that Linux, macOS, and Windows are all supported

Trade-offs

  • The README does not describe the project's current maintenance status beyond a recent last-push date, so long-term support is unclear from this text
  • Some features depend on optional tools such as pyenv or asdf, which must be installed separately
  • Shell completion setup changed in version 2026.5.0, so older guides may be out of date

How it compares

ProjectStarsTypeLevelUpdatedBest for
pipenv (this)25kDev toolbeginner4 days agoPython application developers who want one command set for environments and dependencies
poetry34.3kDev toolintermediate5 days agoPython developers starting a new project who want one config file for dependencies and packaging
pip10.3kDev toolbeginner4 days agoPython developers who need to install and manage third-party libraries
rye14.1kDev toolbeginner9 months agoDevelopers who already run Rye and need a reference for its existing workflow
tsdx11.5kDev toolbeginner9 months agoDevelopers who want to publish a reusable TypeScript library to npm without writing build configuration
UniGetUI26.8kAppbeginner4 days agoWindows users who already use WinGet, Scoop or Chocolatey and want one place to manage them

Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.