How to Install Python PIP on Windows, Mac, and Linux
Python PIP or Python Package Index is an essential tool for managing Python packages and modules. It allows users to install, upgrade, and remove Python packages from the command line or shell. In this guide, we will show you how to install Python PIP on Windows, Mac, and Linux.
Installation Steps for Windows:
- Download the latest version of Python for Windows from the official website (https://www.python.org/downloads/windows/).
- Run the installer and select “Add Python to PATH” during the installation.
- Open the command prompt and type “python ––version” to check if Python is installed correctly.
- Download the get-pip.py script from the official website (https://bootstrap.pypa.io/get-pip.py/).
- Open the command prompt and navigate to the folder where you saved the get-pip.py script.
- Type “python get-pip.py” and press enter to install PIP on Windows.
- To verify if PIP is installed correctly, type “pip –version” in the command prompt.
Installation Steps for Mac:
- Open the terminal and type “python ––version” to check if Python is installed on your system.
- Install Xcode, select “Command Line Tools” from the Preferences menu, and follow the installation instructions.
- Install Homebrew (a package manager for Mac) by running the command “ruby -e “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)”.
- Install PIP by running the command “brew install python”.
- To verify if PIP is installed correctly, type “pip –version” in the terminal.
Installation Steps for Linux:
- Open the terminal and type “python ––version” to check if Python is installed on your system.
- Install PIP by running the command “sudo apt-get install python-pip”.
- To verify if PIP is installed correctly, type “pip –version” in the terminal.
- If the above command doesn’t work on your system, try running the command “sudo apt-get install python-setuptools python-dev build-essential”.
- Once you have installed setuptools and dev tools, run the command “sudo easy_install pip” to install PIP.