How to Install Python & Pip on Ubuntu and Windows
2 Comments on How to Install Python & Pip on Ubuntu and Windows
In today’s tutorial, we are going to go over how to install Python and Pip for your python projects. The first part of this tutorial will go over how to install it on a Ubuntu server, while the second part will go over how to do so on a Windows environment.
Install Python and Pip on Ubuntu Server
Before installing python, you can check whether python is installed on your server running command below
python3 –-version
or:
python –version
If python is not installed — you can install it by running below command:
sudo apt install python3 -y
Installing pip package manager
After installing python, if you type pip on your terminal, you will see message: command not found
Since, we don’t pip package manager installed, run below command to install pip:
sudo apt install python3-pip -y
This module is very important for building your python projects, now let’s see how to install package using pip
pip3 install numpy
If you wish to upgrade any package using pip run below command:
pip3 install -–upgrade numpy
Installing Python on Windows
Open your cmd window in your windows VPS. You can download latest version python following the link below and run the installation:
https://www.python.org/ftp/python/3.10.4/python-3.10.4-amd64.exe
Once installed, you can validate the version using cmd by running below command:
Next, run the below command on cmd – which will download the pip package manager for you.
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
After successfully downloading the pip packager manager, run below command to install pip on your windows VPS server.
python3 get-pip.py
To install a package using pip, run the below command:
pip3 install selenium
Looking for an affordable VPS service, that is instantly set up? Consider RackNerd:
Linux VPS: https://www.racknerd.com/kvm-vps
Windows VPS: https://www.racknerd.com/windows-vps
This guide is essential and important. I would like it to be complemented with the installation of Flask / Django applications on a specific server such as Nginx or LightSpeed. It would be very helpful for those of us who develop in this technology. Thank you very much.
Hi Albert,
Thanks for reading — we sincerely appreciate the suggestion and will pass this feedback on.
Stay tuned and be sure to check out our blog frequently for more tutorials!