Installing PIP on Windows

Ankit Garg
2 min readMar 15, 2018

--

This is a comprehensive guide to install pip on windows OS.

Step 1: Install Python (if you already don’t have).
Python can be easily installed. Just go to https://www.python.org/downloads/ and download the version you need and install the setup.

Verify python installation by typing python --version in the command prompt and will display you the python version if you installing is successful. If somehow it shows any error there might be a problem with your environment variables.

Download Python from here.

Step 2: Download pip installation script.
Downloadget-pip.py, and make sure you save it as .py and not .txt
If you are facing any difficulties, just open the link as save page as get-pip.py

get-pip script

Step 3: Installing PIP
Run the get-pip.py script using command prompt.
Example:
C:\Users\ankit>python get-pip.py

Make sure that you are in the same directory in command prompt as where you have saved your get-pip.py file.
After this PIP will get successfully installed.

Step 4: Verifying Installation
You can verify if pip is correctly installed or not by running the following command in the command prompt.
pip --version
It should output something like this:
pip 9.0.1 from c:\users\ankit\appdata\local\programs\python\python36-32\lib\site-packages (python3.6)

Now you are ready to use pip. Make sure that you are using pip outside the python environment, some users start using pip commands inside python environment and get the following error:

>>> pip — version
Traceback (most recent call last):
File “<stdin>”, line 1, in <module>
NameError: name ‘pip’ is not defined

So avoid this error by not using pip inside python but anywhere outside python environment. If anyhow your code requires pip, use can use it by importing pip first.

--

--

Ankit Garg
Ankit Garg

Written by Ankit Garg

Experienced Cloud Engineer with expertise in search and data warehousing.

No responses yet