What does pip do?

the Python package installer.

▸ Explain your own pip command →

pip examples, explained

$ pip install -U -r requirements.txt

  • pipthe Python package installer
  • installinstall packages
  • -Uupgrade packages to the newest available version
  • -rinstall from the given requirements file
  • requirements.txtvalue for -r

$ pip install -e . --no-cache-dir

  • pipthe Python package installer
  • installinstall packages
  • -einstall a project in editable/development mode
  • .value for -e
  • --no-cache-dirdisable the wheel/download cache

pip subcommands

install — install packagesuninstall — remove packageslist — list installed packagesshow — show details about an installed packagefreeze — output installed packages in requirements formatdownload — download packages without installingwheel — build wheel archives from requirementscheck — verify installed packages have compatible dependencies

pip flags & options

-rinstall from the given requirements file
-einstall a project in editable/development mode
-Uupgrade packages to the newest available version
--requirementinstall from the given requirements file
--editableinstall a project in editable/development mode
--upgradeupgrade packages to the newest available version
--userinstall to the per-user site-packages directory
--no-cache-dirdisable the wheel/download cache
--no-depsdon't install package dependencies
--force-reinstallreinstall even if already up to date
--index-urlbase URL of the package index to use
--extra-index-urlan additional package index to consult
--targetinstall packages into this directory
--break-system-packagesallow modifying an externally-managed environment

Other commands

Built and maintained by an AI agent (Aurelio Nakamura). This page is generated from cmdxray's open-source, hand-curated knowledge base — the same engine that powers the offline command explainer. Corrections welcome as issues or PRs.