How To Install Pip on Windows? – POFTUT

How To Install Pip on Windows?

Pip is a tool used to install Python packages and modules to the operating system. Pip is cross-platform where the same command can be used for both Linux, Windows, MacOSX, etc. In this tutorial, we will install Pip on Windows in different ways.

Download and Install Python

In order to install Pip, the Python should be already installed. We can install Python with the following installation file which is for Python3.

https://www.python.org/ftp/python/3.7.4/python-3.7.4-amd64.exe

After clicking the installation file we will see the following screen where we can provide some installation configuration. Before clicking Install Now to start installation we will check the Add Python 3.7 to PATH which is useful to run python command from the command line in any path.

Python Installation

Python Installation

We will be asked to provide administrative rights to the installation process. We will click to Yes.

The setup process will not take soo much time.

At the end of the successful installation, we will see the following screen. We can simply click to the Close button.

Python Installation Successful

Python Installation Successful

Check Python Installation

We can check the installed Python version in different ways. For Windows, we can use python command or python command with the --version option which will print installed python version in details. python command will start a python interactive shell which will also print installed python version. We can exit from the shell with exit() function.

Check Python Installation

Check Python Installation

Use Python3 Provided Pip Tool

Python 3 provides the pip tool by default. But the tool is installed to the User home path like below. But keep in mind that in this example the user is İsmail Baydan but it should be changed according to your user.

LEARN MORE  How To Convert Python String To Int?

We can navigate to this directly to this path and use the pip command like below.

Install Pip with Get-Pip.py Script On Windows

In order to install Pip for Windows get-pip.py Python script is provided by pypa.io web site. We will download this Python script and run in the command line. While installing the pip via get-pip.py script we can provide --no-setuptools option to prevent setup tools installation and --no-wheel to prevent wheel installation.

We will get the script with curl command or just right click and download. With curl command which is available for Windows 10, Windows Server 2016, Windows Server 2019.

Install Pip with Get-Pip.py Script On Windows

Install Pip with Get-Pip.py Script On Windows

OR with PowerShell Start-BitsTransfer command like below.

We will start the installation by using python command and providing the downloaded script file get-pip.py like below.

Install Pip with Get-Pip.py Script On Windows

Install Pip with Get-Pip.py Script On Windows

Check Installed Pip Version

After installing pip we can check its version. We can use the --version option in order to print the currently installed Pip version.

Upgrade/Update Pip

We can update or upgrade already install pip command with the -U option and provide the pip as package name.

LEARN MORE  Pip ffi.h Gcc Error

Install Behind the Proxy

If we are in a corporate where it uses some proxy for internet traffic control we need to provide some proxy information in order to access and download the Pip package. We will use --proxy configuration with the proxy address, port, username, and password.

Search/Find A Package with Pip

We can use the search command of Pip in order to search and find a package or list multiple packages which are related to the search term. In this example, we will search the package named django.

Install A Package with Pip

We can install a package with the install Pip command. In this example, we will install the package named django like below.

Uninstall A Package with Pip

We can uninstall the installed package with the uninstall command of Pip. In this example, we will uninstall the package named django.

Leave a Reply

Your email address will not be published. Required fields are marked *