Python is a versatile, high-level programming language that is widely supported across all major operating systems.
You can run Python on your computer using the following two methods:
- Run Python online
- Install Python on your computer
In this tutorial, you will learn both methods.
Run Python Online
To execute Python code, you need to have a Python interpreter installed on your system. However, if you want to start immediately, you can use our free online Python editor.
The online editor enables you to run Python code directly in your browser—no installation required.
Install Python on Your Computer
For those who prefer to install Python on your computer, this guide will walk you through the installation process on Windows, macOS, and Linux (Ubuntu).
To install Python on your Windows, just follow these steps:
- Install VS Code
- Download Python Installer File
- Run the Installer
- Install Python
- Verify your installation
Here is a detailed explanation of each of the steps:
Step 1: Install VS Code
Go to the VS Code Official website and download the Windows installer. Once the download is complete, run the installer and follow the installation process.
Click Finish to complete the installation process
Step 2: Download the Python Installer File
Go to the official Python website and download the latest version (Python 3.12.2 at the time of writing this tutorial) for Windows.
The website automatically detects your operating system and gives you the right installer.
Step 3: Run the Installer
Now, go to your download folder and run the installer you just downloaded. Depending on your security settings, you might be prompted to allow access.
Simply allow it and proceed.
Step 4: Install Python
Once you have run the installer, you will come across this screen.
On the screen, you will see two options: Install Now and Customize Installation. We suggest you skip all customization steps and simply click Install Now.
- Check on Add python.exe to PATH as it ensures Python is added to our system's PATH variable.(Recommended)
- Click Install Now, as it will include all the necessary files needed later.
This makes it easier to run a Python Program from the command prompt (cmd) directly without specifying the full path of the Python executable.
After using this option, Python will be successfully installed in your device.
