1PIP-INSTALL(1) pip PIP-INSTALL(1)
2
3
4
6 pip-install - description of pip install command
7
9 Install packages from:
10
11 · PyPI (and other indexes) using requirement specifiers.
12
13 · VCS project urls.
14
15 · Local project directories.
16
17 · Local or remote source archives.
18
19 pip also supports installing from "requirements files", which provide
20 an easy way to specify a whole environment to be installed.
21
22
24 pip install [options] <requirement specifier> [package-index-options] ...
25 pip install [options] -r <requirements file> [package-index-options] ...
26 pip install [options] [-e] <vcs project url> ...
27 pip install [options] [-e] <local project path> ...
28 pip install [options] <archive url/path> ...
29
31 -r, --requirement <file>
32 Install from the given requirements file. This option can be
33 used multiple times.
34
35 -c, --constraint <file>
36 Constrain versions using the given constraints file. This option
37 can be used multiple times.
38
39 --no-deps
40 Don't install package dependencies.
41
42 --pre Include pre-release and development versions. By default, pip
43 only finds stable versions.
44
45 -e, --editable <path/url>
46 Install a project in editable mode (i.e. setuptools "develop
47 mode") from a local project path or a VCS url.
48
49 -t, --target <dir>
50 Install packages into <dir>. By default this will not replace
51 existing files/folders in <dir>. Use --upgrade to replace exist‐
52 ing packages in <dir> with new versions.
53
54 --platform <platform>
55 Only use wheels compatible with <platform>. Defaults to the
56 platform of the running system.
57
58 --python-version <python_version>
59 The Python interpreter version to use for wheel and
60 "Requires-Python" compatibility checks. Defaults to a version
61 derived from the running interpreter. The version can be speci‐
62 fied using up to three dot-separated integers (e.g. "3" for
63 3.0.0, "3.7" for 3.7.0, or "3.7.3"). A major-minor version can
64 also be given as a string without dots (e.g. "37" for 3.7.0).
65
66 --implementation <implementation>
67 Only use wheels compatible with Python implementation <implemen‐
68 tation>, e.g. 'pp', 'jy', 'cp', or 'ip'. If not specified, then
69 the current interpreter implementation is used. Use 'py' to
70 force implementation-agnostic wheels.
71
72 --abi <abi>
73 Only use wheels compatible with Python abi <abi>, e.g.
74 'pypy_41'. If not specified, then the current interpreter abi
75 tag is used. Generally you will need to specify --implementa‐
76 tion, --platform, and --python-version when using this option.
77
78 --user Install to the Python user install directory for your platform.
79 Typically ~/.local/, or %APPDATA%Python on Windows. (See the
80 Python documentation for site.USER_BASE for full details.)
81
82 --root <dir>
83 Install everything relative to this alternate root directory.
84
85 --prefix <dir>
86 Installation prefix where lib, bin and other top-level folders
87 are placed
88
89 -b, --build <dir>
90 Directory to unpack packages into and build in. Note that an
91 initial build still takes place in a temporary directory. The
92 location of temporary directories can be controlled by setting
93 the TMPDIR environment variable (TEMP on Windows) appropriately.
94 When passed, build directories are not cleaned in case of fail‐
95 ures.
96
97 --src <dir>
98 Directory to check out editable projects into. The default in a
99 virtualenv is "<venv path>/src". The default for global installs
100 is "<current dir>/src".
101
102 -U, --upgrade
103 Upgrade all specified packages to the newest available version.
104 The handling of dependencies depends on the upgrade-strategy
105 used.
106
107 --upgrade-strategy <upgrade_strategy>
108 Determines how dependency upgrading should be handled [default:
109 only-if-needed]. "eager" - dependencies are upgraded regardless
110 of whether the currently installed version satisfies the
111 requirements of the upgraded package(s). "only-if-needed" - are
112 upgraded only when they do not satisfy the requirements of the
113 upgraded package(s).
114
115 --force-reinstall
116 Reinstall all packages even if they are already up-to-date.
117
118 -I, --ignore-installed
119 Ignore the installed packages, overwriting them. This can break
120 your system if the existing package is of a different version or
121 was installed with a different package manager!
122
123 --ignore-requires-python
124 Ignore the Requires-Python information.
125
126 --no-build-isolation
127 Disable isolation when building a modern source distribution.
128 Build dependencies specified by PEP 518 must be already
129 installed if this option is used.
130
131 --use-pep517
132 Use PEP 517 for building source distributions (use
133 --no-use-pep517 to force legacy behaviour).
134
135 --install-option <options>
136 Extra arguments to be supplied to the setup.py install command
137 (use like --install-option="--install-scripts=<sys.pre‐
138 fix>/local/bin"). Use multiple --install-option options to pass
139 multiple options to setup.py install. If you are using an option
140 with a directory path, be sure to use absolute path.
141
142 --global-option <options>
143 Extra global options to be supplied to the setup.py call before
144 the install command.
145
146 --compile
147 Compile Python source files to bytecode
148
149 --no-compile
150 Do not compile Python source files to bytecode
151
152 --no-warn-script-location
153 Do not warn when installing scripts outside PATH
154
155 --no-warn-conflicts
156 Do not warn about broken dependencies
157
158 --no-binary <format_control>
159 Do not use binary packages. Can be supplied multiple times, and
160 each time adds to the existing value. Accepts either :all: to
161 disable all binary packages, :none: to empty the set, or one or
162 more package names with commas between them (no colons). Note
163 that some packages are tricky to compile and may fail to install
164 when this option is used on them.
165
166 --only-binary <format_control>
167 Do not use source packages. Can be supplied multiple times, and
168 each time adds to the existing value. Accepts either :all: to
169 disable all source packages, :none: to empty the set, or one or
170 more package names with commas between them. Packages without
171 binary distributions will fail to install when this option is
172 used on them.
173
174 --prefer-binary
175 Prefer older binary packages over newer source packages.
176
177 --no-clean
178 Don't clean up build directories.
179
180 --require-hashes
181 Require a hash to check each requirement against, for repeatable
182 installs. This option is implied when any package in a require‐
183 ments file has a --hash option.
184
185 --progress-bar <progress_bar>
186 Specify type of progress to be displayed
187 [off|on|ascii|pretty|emoji] (default: on)
188
189
191 pip developers
192
194 2008-2020, PyPA
195
196
197
198
19919.3 April 10, 2020 PIP-INSTALL(1)