Python is a general purpose popular programming language used for web and software development or system scripting. It is a free open source language. Python works on different platforms (Windows, Mac, Linux, etc.).
Windows Operating system doesn't come installed with Python. Python package is available from Microsoft Store from Windows 10/11. It is also pretty simple to download and install from the python.org website.
In this tutorial we learn how to install Python on Windows 10/11.
Install Python on Windows
Python 3.9 supports Windows 8.1 and higher versions. Lets check here Python installation using the .exe installer and the package from Microsoft Store.
If you are experience programmer the recommended installation method is get the installer from official website.
Install using Python .exe installer
This installation option contains a full-featured Python development environment and is the best option for experienced developers. This allows adding Python to
PATH if necessary. Follow the step-by-step guide below to install.
01. Download the full .exe installer from the official Python website (Python.org) Downloads for Windows section.
02. Select the desired and compatible version of Python. For this guide, the latest version which is Python 3.8.5 (64 bit) .exe installer is selected.
03. Run the Python Installer once downloaded.
04. Select the Install launcher for all users and Add Python 3.9 to PATH checkboxes. The latter places the interpreter in the execution path. Clink Install Now.
05. At the end of installation, select whether to Disable path length limit. Choosing this option will effectively enable Python to use long path names.
06. Verify the installation of Python by running the command
python in the Command Prompt. The output should be similar to what you can see below:
Install Python from Microsoft Store
Installing Python from Microsoft Store is designed to be used by students and people learning to use Python for the first time. Installing via the Microsoft Store is suitable for running scripts and packages, and using IDLE or other development environments.
Follow the step-by-step guide below to install.
01. Search for Python 3.9 at the Microsoft Store. Click Get to download and install.
Note: Make sure that the Python application you’ve selected is created by the Python Software Foundation.
02. The message "This product is installed" pops-out when installation was successful.
03. Verify the installation of Python by running the command
python in the Command Prompt or PowerShell.
To check where is python install, type the following command in command prompt or PowerShell:
PIP is by default installed along with Python 3.4+ and it comes with the virtualenv and pyvenv virtual environments.
To verify whether Pip was installed:
01. Open Command Prompt.
pip -V in the console. If Pip was installed successfully, you should see the following output:
Add Python to PATH
These steps are applicable if you were unable to tick the Add Python to Path checkbox during the installation and for older versions of Python that do not support the Add Python to Path checkbox.
01. Open the Run app on the search taskbar button.
02. Type sysdm.cpl and click OK. This will open the System Properties window.
03. Navigate to the Advanced tab and select Environment Variables.
04. Under System Variables, find and select the Path variable. Click edit.
05. Add the path to the python.exe file. For example, we have added "C:\Python39." Click OK to apply.
06. To test it, open Command Prompt and type the command
PATH. You should see the following output:
How to Run a Python Program
Create a file named script.py and add below python code
print("Welcome ! Python is working.")
Now go to Powershell or command prompt, type
Welcome ! Python is working.
How to uninstall Python
To uninstall Python from Windows 10:
01. Open Control Panel > Uninstall a program.
02. Select the Python version to uninstall. Then click the Uninstall button above the list – this has to be done for every Python version installed on the system.
03. Wait for the successful uninstallation status.
In this tutorial, we learned how to install Python 3.9 on Windows 10/11. You’re now ready to get started programming in Python!
* You will receive the latest news and updates directly to your inbox !