How to install Python on Windows

Learn how to install Python on your Windows machine in just a few steps.

How to install Python on Windows

Follow these steps:

Step 1: Download Python

  1. Go to the official Python website.
  2. On the Downloads page, you'll find the latest Python version. Click on the Download Python button.
  3. This will download the Python installer for Windows (e.g., python-3.x.x.exe).

Step 2: Run the Installer

  1. Open the installer by double-clicking the .exe file you just downloaded.
  2. Important: Check the box that says "Add Python to PATH". This ensures Python is added to your system's environment variables, making it accessible from the command line.
  3. Click on Install Now to proceed with the installation.

Step 3: Verify Installation

  1. After the installation is complete, open the Command Prompt (you can search for it in the Start menu).
  2. Type the following command and press Enter:
python --version

If Python was installed correctly, this will display the installed version of Python.

  1. You can also check if pip (Python's package manager) is installed by typing:
pip --version

If both commands return the version details, Python has been successfully installed.

Step 4: Install Additional Libraries (Optional)

You can install libraries using pip. For example, to install the numpy package, use:

  pip install numpy

You're now ready to start programming in Python on Windows!