PIP-INSTALL(1)
π pip-install(1) β the pip manual, bestie edition π
okay so this is a page from the pip manual set (we're in section 1, the commands section, periodt), and it's literally all about pip install. grab a snack, we're going through every single flag together π
β¨ NAME β¨
pip-install β the description of the pip install command. that's it, that's the name, she's simple and she's iconic π
πΈ DESCRIPTION πΈ
So pip install installs packages for you. From where? bestie, from so many places:
- PyPI (and other indexes!) using requirement specifiers. yes queen, the classic move π
- VCS project urls β straight from the repo, living dangerously π
- Local project directories β your own lil folder of code π¦
- Local or remote source archives β tarballs, zips, the works π
and pip also supports installing from "requirements files", which are lowkey the best thing ever because they let you specify an entire environment to be installed in one go. one file, whole vibe, immaculate. β¨
π§ USAGE π§
here's the whole shape of it, copy these exactly:
python -m pip install [options] <requirement specifier> [package-index-options] ...
python -m pip install [options] -r <requirements file> [package-index-options] ...
python -m pip install [options] [-e] <vcs project url> ...
python -m pip install [options] [-e] <local project path> ...
python -m pip install [options] <archive url/path> ...
pick your fighter, they're all valid π
π OPTIONS π
this is the long part and honestly? it's giving main character energy. every option, every env var, no cap, nothing skipped:
-r,--requirement <file>β install from the given requirements file, and yes you can use this option multiple times. stack 'em up π«Ά (environment variable:PIP_REQUIREMENT)-c,--constraint <file>β constrain versions using the given constraints file. this option can also be used multiple times. it's giving boundaries, and honestly healthy π (environment variable:PIP_CONSTRAINT)--no-depsβ don't install package dependencies. lone wolf behavior, respect πΊ (environment variable:PIP_NO_DEPS,PIP_NO_DEPENDENCIES)--preβ include pre-release and development versions. by default, pip only finds stable versions, so this is you saying "i want the experimental one, i'm brave" π (environment variable:PIP_PRE)-e,--editable <path/url>β install a project in editable mode (i.e. setuptools "develop mode") from a local project path or a VCS url. live-editing your code as you install it? obsessed β¨ (environment variable:PIP_EDITABLE)--dry-runβ don't actually install anything, just print what would be. rehearsal era π it can be used in combination with--ignore-installedto 'resolve' the requirements. (environment variable:PIP_DRY_RUN)-t,--target <dir>β install packages into <dir>. by default this will not replace existing files/folders in <dir>. use--upgradeto replace existing packages in <dir> with new versions. gentle by default, ruthless on request π (environment variable:PIP_TARGET)--platform <platform>β only use wheels compatible with <platform>. defaults to the platform of the running system. use this option multiple times to specify multiple platforms supported by the target interpreter π (environment variable:PIP_PLATFORM)--python-version <python_version>β the Python interpreter version to use for wheel and "Requires-Python" compatibility checks. defaults to a version derived from the running interpreter. the version can be specified using up to three dot-separated integers (e.g."3"for3.0.0,"3.7"for3.7.0, or"3.7.3"). a major-minor version can also be given as a string without dots (e.g."37"for3.7.0) β dots are optional, the drama is not π (environment variable:PIP_PYTHON_VERSION)--implementation <implementation>β only use wheels compatible with Python implementation <implementation>, e.g.'pp','jy','cp', or'ip'. if not specified, then the current interpreter implementation is used. use'py'to force implementation-agnostic wheels. unbothered, implementation-free πΈ (environment variable:PIP_IMPLEMENTATION)--abi <abi>β only use wheels compatible with Python abi <abi>, e.g.'pypy_41'. if not specified, then the current interpreter abi tag is used. use this option multiple times to specify multiple abis supported by the target interpreter. generally you will need to specify--implementation,--platform, and--python-versionwhen using this option β they're a package deal, iykyk π (environment variable:PIP_ABI)--userβ install to the Python user install directory for your platform. typically~/.local/, or%APPDATA%Pythonon Windows. (see the Python documentation forsite.USER_BASEfor full details.) your own lil corner of the disk π‘ (environment variable:PIP_USER)--root <dir>β install everything relative to this alternate root directory π³ (environment variable:PIP_ROOT)--prefix <dir>β installation prefix wherelib,binand other top-level folders are placed. note that the resulting installation may contain scripts and other resources which reference the Python interpreter of pip, and not that of--prefix. see also the--pythonoption if the intention is to install packages into another (possibly pip-free) environment. heads up bestie, this one's got lore β οΈ (environment variable:PIP_PREFIX)--src <dir>β directory to check out editable projects into. the default in a virtualenv is"<venv path>/src". the default for global installs is"<current dir>/src"ποΈ (environment variable:PIP_SRC,PIP_SOURCE,PIP_SOURCE_DIR,PIP_SOURCE_DIRECTORY)-U,--upgradeβ upgrade all specified packages to the newest available version. the handling of dependencies depends on the upgrade-strategy used. glow-up time π₯ (environment variable:PIP_UPGRADE)--upgrade-strategy <upgrade_strategy>β determines how dependency upgrading should be handled [default:only-if-needed]."eager"β dependencies are upgraded regardless of whether the currently installed version satisfies the requirements of the upgraded package(s)."only-if-needed"β are upgraded only when they do not satisfy the requirements of the upgraded package(s). two strategies, two vibes π (environment variable:PIP_UPGRADE_STRATEGY)--force-reinstallβ reinstall all packages even if they are already up-to-date. no thoughts, just reinstall π (environment variable:PIP_FORCE_REINSTALL)-I,--ignore-installedβ ignore the installed packages, overwriting them. this can break your system if the existing package is of a different version or was installed with a different package manager! fr fr, do not do this casually π (environment variable:PIP_IGNORE_INSTALLED)--ignore-requires-pythonβ ignore theRequires-Pythoninformation. rules are fake actually βοΈ (environment variable:PIP_IGNORE_REQUIRES_PYTHON)--no-build-isolationβ disable isolation when building a modern source distribution. build dependencies specified by PEP 518 must be already installed if this option is used β no isolation means you showed up with your own supplies π (environment variable:PIP_NO_BUILD_ISOLATION)--use-pep517β use PEP 517 for building source distributions (use--no-use-pep517to force legacy behaviour). modern era only π« (environment variable:PIP_USE_PEP517)--check-build-dependenciesβ check the build dependencies when PEP517 is used π (environment variable:PIP_CHECK_BUILD_DEPENDENCIES)--break-system-packagesβ allow pip to modify anEXTERNALLY-MANAGEDPython installation. yes the name is dramatic, yes it's accurate π (environment variable:PIP_BREAK_SYSTEM_PACKAGES)-C,--config-settings <settings>β configuration settings to be passed to the PEP 517 build backend. settings take the formKEY=VALUE. use multiple--config-settingsoptions to pass multiple keys to the backend. key-value slay π (environment variable:PIP_CONFIG_SETTINGS)--global-option <options>β extra global options to be supplied to thesetup.pycall before theinstallorbdist_wheelcommand π οΈ (environment variable:PIP_GLOBAL_OPTION)--compileβ compile Python source files to bytecode β‘ (environment variable:PIP_COMPILE)--no-compileβ do not compile Python source files to bytecode π« (environment variable:PIP_NO_COMPILE)--no-warn-script-locationβ do not warn when installing scripts outsidePATH. ignorance is bliss β¨ (environment variable:PIP_NO_WARN_SCRIPT_LOCATION)--no-warn-conflictsβ do not warn about broken dependencies. la la la can't hear you π§ (environment variable:PIP_NO_WARN_CONFLICTS)--no-binary <format_control>β do not use binary packages. can be supplied multiple times, and each time adds to the existing value. accepts either":all:"to disable all binary packages,":none:"to empty the set (notice the colons), or one or more package names with commas between them (no colons). note that some packages are tricky to compile and may fail to install when this option is used on them β you've been warned, bestie β οΈ (environment variable:PIP_NO_BINARY)--only-binary <format_control>β do not use source packages. can be supplied multiple times, and each time adds to the existing value. accepts either":all:"to disable all source packages,":none:"to empty the set, or one or more package names with commas between them. packages without binary distributions will fail to install when this option is used on them β binaries only, no exceptions π (environment variable:PIP_ONLY_BINARY)--prefer-binaryβ prefer binary packages over source packages, even if the source packages are newer. loyalty to binaries fr π«Ά (environment variable:PIP_PREFER_BINARY)--require-hashesβ require a hash to check each requirement against, for repeatable installs. this option is implied when any package in a requirements file has a--hashoption π (environment variable:PIP_REQUIRE_HASHES)--progress-bar <progress_bar>β specify whether the progress bar should be used [on,off,raw] (default:on) π (environment variable:PIP_PROGRESS_BAR)--root-user-action <root_user_action>β action if pip is run as a root user [warn,ignore] (default:warn) π (environment variable:PIP_ROOT_USER_ACTION)--report <file>β generate a JSON file describing what pip did to install the provided requirements. can be used in combination with--dry-runand--ignore-installedto 'resolve' the requirements. when-is used as file name it writes to stdout. when writing to stdout, please combine with the--quietoption to avoid mixing pip logging output with JSON output β otherwise it's a mess and nobody can read it π (environment variable:PIP_REPORT)--group <[path:]group>β install a named dependency-group from a"pyproject.toml"file. if a path is given, the name of the file must be"pyproject.toml". defaults to using"pyproject.toml"in the current directory. groups era π (environment variable:PIP_GROUP)--no-cleanβ don't clean up build directories. leave the mess, it's authentic π§ (environment variable:PIP_NO_CLEAN)
π¦ AUTHOR π¦
pip developers β legends, every one of them π«Ά
β COPYRIGHT β
the pip developers π
and that's the whole page, bestie! π this was pip 25.1, dated Jun 26, 2025 β go forth and pip install responsibly, mwah πβ¨
π¦ where this page comes from
- epel 9: python3.13-pip 25.1.1-1.el9 Β· MIT AND Python-2.0.1 AND Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MPL-2.0 AND (Apache-2.0 OR BSD-2-Clause)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms