Environment variables¶
pipx has no user configuration file. Every setting is an environment variable, all of them optional. Run pipx
environment to print each variable as set in your environment, followed by the values pipx derives from them.
Settable variables¶
Variable |
Meaning and default |
|---|---|
|
Root directory for pipx virtual environments. Default: |
|
Directory for application entry-point symlinks. Default: |
|
Directory for man page symlinks. Default: |
|
Directory for shell completion symlinks. Default: |
|
Root directory for global ( |
|
Entry-point directory for global installs. Default: |
|
Man page directory for global installs. Default: |
|
Shell completion directory for global installs. Default: |
|
Override the shared libraries directory. pipx ignores it with |
|
Python interpreter used when |
|
Backend for new venvs, |
|
Default for |
|
When to fetch a standalone Python build: |
|
Deprecated alias for |
|
Set to a truthy value to skip automatic shared library upgrades. Default: unset. |
|
Set to |
|
Number of command logs to keep in the log directory, counting the current command’s; pip and |
Note
pipx falls back to USE_EMOJI (unprefixed) when PIPX_USE_EMOJI is unset.
Note
pipx forwards the standard PIP_* environment variables (for example PIP_INDEX_URL) to pip, except that
it forces PIP_USER=0 and PIP_DISABLE_PIP_VERSION_CHECK=1, drops PIP_TARGET, and defaults
PIP_KEYRING_PROVIDER to subprocess. See Troubleshoot if pip behaves
unexpectedly.
Legacy fallback home¶
If a legacy home directory already exists on disk, pipx keeps its virtual environments there instead of the
PIPX_HOME default: ~/.local/pipx on any platform, and ~\pipx on Windows. pipx uses them only when present
and when PIPX_HOME is unset. See Configure paths to migrate off them.
On Unix, a pipx installation that manages itself recovers PIPX_HOME and PIPX_DEFAULT_PYTHON from its own
virtual environment when those variables are unset, and PIPX_BIN_DIR when pipx was launched through its exposed
link, so later shells stay attached to the same installation.
A pipx installed with --global lives in the global home (PIPX_GLOBAL_HOME, /opt/pipx by default) and
recovers only PIPX_DEFAULT_PYTHON: without --global it uses the per-user defaults, with --global the global
ones. With a custom PIPX_GLOBAL_HOME, every user who runs that pipx must set it; otherwise pipx treats the global
home as their own PIPX_HOME. pipx recovers
PIPX_DEFAULT_PYTHON only while the recorded interpreter still resolves to the one its environment runs on; it
ignores a record left pointing into a removed bootstrap environment and falls back to its own interpreter.
Derived (read-only) values¶
pipx environment also reports the following values. pipx computes them from the settable variables and the
platform; they are reported, not set.
Value |
Meaning |
|---|---|
|
Directory holding the per-package virtual environments ( |
|
Directory holding command logs. |
|
Staging directory for deletions on the same filesystem as the venvs. |
|
Cache directory for |
|
Cache directory for downloaded standalone Python builds. |
|
Backend pipx resolved for new venvs ( |
|
Where the resolved backend came from: |
|
Path to the |
|
Value of |