I usually just run the following commands to upgrade both pip2 (=pip by default) and pip3:

sudo -H pip3 install --upgrade pip
sudo -H pip2 install --upgrade pip

You must make sure that you upgrade the version (for Python 2 or 3), which you want to react on the command pip without number, last.

Also please note that this keeps the old packaged versions installed through apt-get or any other package manager, but adds new versions which have nothing to do with the system packages. The pip-installed packages will be preferred, but you should not remove the apt-get-installed ones either, because the package manager can't know that any pip version is installed otherwise.

Answer from Byte Commander on askubuntu.com
🌐
GeeksforGeeks
geeksforgeeks.org › python › how-to-upgrade-pip-and-python-on-windows-linux-and-macos
How to Upgrade Pip and Python on Windows, Linux, and MacOS? - GeeksforGeeks
January 30, 2026 - Installing Python Pip in Ubuntu ... the Pip and Python manually, then please run the following commands one by one: sudo apt upgrade python3 sudo apt upgrade python3-pip ·...
Discussions

python - How should I upgrade pip on Ubuntu 14.04? - Stack Overflow
I want to get the most recent version (8.1.2) of pip. I'm using Ubuntu 14.04 and python 2.7.6. The version of pip in the Ubuntu repositories is only 1.5.4 (and can't install things like numpy). Ho... More on stackoverflow.com
🌐 stackoverflow.com
April 17, 2018
linux - How can I upgrade pip on Ubuntu 10.04? - Unix & Linux Stack Exchange
I tried that, it said that it upgraded but then using pip --version still gives the same version. ... I suggest you to use virtualenv. For further details see the Official pip documentation ... I would use easy_install pip instead of the curl command. ... A more elegant solution would be to ask for backporting python-pip 1.0-1 from Ubuntu ... More on unix.stackexchange.com
🌐 unix.stackexchange.com
python - How to upgrade pip3? - Stack Overflow
My windows 10 command line suggested c:\python3\python3.exe -m pip install --upgrade setuptools pip 2019-02-05T13:46:50.463Z+00:00 ... Works for mac, which python3 was installed from .dmg file. 2019-03-11T04:13:15.673Z+00:00 ... sudo python3 -m pip uninstall pip && sudo apt install python3-pip --reinstall solved the ImportError problem for me. Environment is ubuntu ... More on stackoverflow.com
🌐 stackoverflow.com
Python Pip broken after updating...
Partial update or sudo pip install? More on reddit.com
🌐 r/archlinux
25
3
February 1, 2021
People also ask

Can I use `pip install --upgrade pip` to upgrade PIP?
While this command can work, it's better to use `python -m pip install --upgrade pip` to ensure the correct Python version is used.
🌐
blog.openreplay.com
blog.openreplay.com › openreplay blog › how to upgrade pip: a full guide for windows, macos, and linux
How to Upgrade PIP: A Full Guide for Windows, macOS, and Linux
Will upgrading PIP affect my existing Python packages?
In most cases, upgrading PIP won't affect your existing packages. However, it's always a good practice to create a virtual environment for each project to isolate dependencies.
🌐
blog.openreplay.com
blog.openreplay.com › openreplay blog › how to upgrade pip: a full guide for windows, macos, and linux
How to Upgrade PIP: A Full Guide for Windows, macOS, and Linux
Do I need to upgrade PIP for each Python version separately?
Yes, if you have multiple Python versions installed, you need to upgrade PIP for each version independently.
🌐
blog.openreplay.com
blog.openreplay.com › openreplay blog › how to upgrade pip: a full guide for windows, macos, and linux
How to Upgrade PIP: A Full Guide for Windows, macOS, and Linux
🌐
pip
pip.pypa.io › en › stable › installation
Installation - pip documentation v26.1.2
C:> py -m ensurepip --upgrade · More details about how ensurepip works and how it can be used, is available in the standard library documentation. This is a Python script that uses some bootstrapping logic to install pip. Download the script, from https://bootstrap.pypa.io/get-pip.py.
🌐
DataCamp
datacamp.com › tutorial › pip-upgrade-python
How to Upgrade Pip and Python in Windows, MacOS, and Linux | DataCamp
December 23, 2025 - For Linux users, the upgrade process may vary slightly depending on the distribution, such as Ubuntu or Fedora. The first step is to update the package list. You can do this by opening your terminal and running the following command: ... You can then upgrade Python by installing the latest version. Open your terminal and run the following command: ... The next step is to upgrade Pip.
Find elsewhere
🌐
OpenReplay
blog.openreplay.com › openreplay blog › how to upgrade pip: a full guide for windows, macos, and linux
How to Upgrade PIP: A Full Guide for Windows, macOS, and Linux
December 20, 2024 - Can I use `pip install --upgrade pip` to upgrade PIP? While this command can work, it's better to use `python -m pip install --upgrade pip` to ensure the correct Python version is used.
🌐
AmazingRDP
amazingrdp.com › home › how to upgrade pip on ubuntu
How to Upgrade Pip on Ubuntu | AmazingRDP
September 19, 2024 - Learn how to easily upgrade Pip, the Python package manager, on Ubuntu with simple terminal commands.
🌐
NBShare
nbshare.io › notebook › 228803083 › How-to-Upgrade-Python-PIP
How to Upgrade Python PIP - Nbshare Notebooks
To install the version we can either run the command pip install --upgrade pip or do pip install pip==19.3.1
🌐
bodHOST
bodhost.com › general discussion › how to upgrade pip on linux
How to Upgrade Pip on Linux | bodHOST
February 26, 2026 - Cleaning (Optional): You can use the following command to get rid of the outdated Pip version: ... Replace ‘<old_pip_version>’ with the version number you wish to remove. Your Linux system has now been successfully upgraded with Pip. It is crucial to remember that pip might be available as a stand-alone package that can be updated using the system’s package management in some Linux distributions, such as Ubuntu...
🌐
Caasify
caasify.com › home › blog › how to upgrade pip package: the ultimate guide for 2025
How To Upgrade Pip Package: The Ultimate Guide for 2025 | Caasify
December 8, 2025 - Below is an example of a simple workflow configuration: name: CI Pipeline on: push: branches: - main jobs: build: runs-on: ubuntu-latest steps: - name: Checkout code uses: actions/checkout@v2 - name: Upgrade pip run: pip install --upgrade pip - ...
🌐
MonoVM
monovm.com › blog › tutorials › how to upgrade pip package to latest version [pip update]
How to Upgrade Pip Package to Latest Version [Pip Update]
January 30, 2024 - Cleanup (Optional): If you want ... following command: ... Replace `<old_pip_version>` with the version number you wish to remove. Now you have successfully upgraded Pip on your Linux system. It's important to note that some Linux distributions, like Ubuntu, may provide Pip ...
🌐
Python⇒Speed
pythonspeed.com › articles › upgrade-pip
Why you should upgrade pip, and how to do it
March 21, 2023 - In general, you can do pip install --upgrade pip and call it a day. However, in some environments that can have issues. For example, if you look above at how we setup Python in Ubuntu 18.04, we installed pip from a system package.
🌐
Cherry Servers
cherryservers.com › home › blog › cloud computing › how to install pip on ubuntu 22.04 | step-by-step
How to Install PIP on Ubuntu 22.04 | Step-by-Step | Cherry Servers
February 20, 2026 - ... The output provides information such as the name, version, author, and a brief summary of the package among other details. To upgrade a Python package to its latest version, invoke the --upgrade or -U option.
🌐
Anglehit
anglehit.com › how-should-i-upgrade-pip-on-ubuntu
How should I upgrade pip on Ubuntu? – Anglehit
January 29, 2020 - Let’s say you’ve copied a giant ... this command. Phew!!! Solution: This can be achieved using a python ... This post is relative to all the novice as well as seasoned users on laptop specially — considering Lenovo and Dell. The common issue that I’ve heard from my friend is that my laptop co ... This is a persistent issue and is faced on Ubuntu 20.04 LTS ...
🌐
Codedamn
codedamn.com › news › python
How to Update Pip and Python On Your System With Pip Upgrade
June 22, 2023 - For Debian-based systems (e.g., Ubuntu), run the following commands: ... After updating, verify the updated version by running python --version or python3 --version, depending on the version you installed.
🌐
pip
pip.pypa.io › en › latest › installation
Installation - pip documentation v26.2.dev0
C:> py -m ensurepip --upgrade · More details about how ensurepip works and how it can be used, is available in the standard library documentation. This is a Python script that uses some bootstrapping logic to install pip. Download the script, from https://bootstrap.pypa.io/get-pip.py.