How to fix the pip command not found error? [Solution]

How to fix the pip command not found error? While installing certain packages over Python, you have to work with the PIP command, and you are getting a common error, i.e., Bash: PIP command not found.

Updated: 03 Aug, 23 by Susith Nonis 3 Min

List of content you will read in this article:

PIP is a Python dependency and library package manager. It is typically installed alongside Python 3x and Python 2x. However, in rare cases, you may encounter the "pip command not found" error while installing a library or python package. This article will cover the causes of this error and simple solutions for resolving it. The methods discussed here apply to both Linux operating systems and Windows users.

PIP is a package manager for Python packages. It helps the users install and manage different Python packages and frameworks. Pip is installed along with Python from Python versions 3.4 and above. Pip is similar to the package managers of Linux Operating Systems like apt-get, yum, etc. 

Solution 1: Install Python

As we mentioned, from Python 3.4, we know how to install pip along with Python. Therefore, we can try installing Python on the machine to eliminate this error.

Step 1: Visit the official webpage to install Python on your machine. There, you will see different Python versions available for download. Choose a suitable package and download the executable installer.

Step 2: Once the executable file is downloaded, open the file by going to the Download folder, double-click on the file to start the installation process, and click "Install Now" to start the installation process.

Once Python is installed, you will see the below window in the installer.

Step 3: To verify the pip installation, enter the pip -v command in the Command Prompt to see the pip version.

Step 4: To install Python on Debian based Linux distributions, download Python from the same official website and enter the following command in the terminal:

$ sudo apt-get install python3.8

Once Python is installed, you can verify the installation of python using the command below.

python --version

Solution 2: Use easy_install

If you are using Python 2, you need to install pip separately. Execute the following command in Linux to get pip for Python 2x versions.

$ sudo easy_install pip

Solution 3: Use pip3 instead of pip

You could also specify the version of pip as normal pip command may not work with Python 3x in some cases. For this, use pip3 instead of pip while installing a package.

Solution 3: Upgrade the PIP version

upgrade pip to the latest version with the command below.

$ pip install --upgrade pip

We went over the solutions to the how-to resolve "pip command not found" error in this article. We discovered several possible causes for this problem, which can be resolved by installing Python from scratch, installing a different version of pip, or specifying the pip version when installing the packages. If you feel we can have other alternatives, you can suggest them in the comment box below.

You can buy our Debian VPS server to work with a Debian server for more security.

Keep reading.

People also read: 

Susith Nonis

Susith Nonis

I'm fascinated by the IT world and how the 1's and 0's work. While I venture into the world of Technology, I try to share what I know in the simplest way with you. Not a fan of coffee, a travel addict, and a self-accredited 'master chef'.