Bootstrap pip into the current interpreter or venv.
Section: Repair pip and packaging state
Install bundled pip
bash
bash
python -m ensurepip --default-pipExplanation
Use this when pip is missing after environment creation or corruption.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Repair pip and packaging state
Upgrade bundled pip
Reinstall or upgrade pip from the standard library bundle.
Purge cache during package troubleshooting
Clear cached artifacts before retrying installs.
Use python -m pip for installs
Avoid ambiguity by tying pip to the active interpreter.