Pylerno
English

Windows installation

Use PowerShell for these steps. By the end you will have a project folder and a Python interpreter dedicated to it.

On this page

Install the runtime

  1. Open Python for Windows and choose the Python install manager.
  2. Open the downloaded installer and choose Install. When it finishes, open a new PowerShell window.
  3. Run these commands one at a time. The first asks the manager to install Python 3.14, a supported runtime for every project in this handbook. The second prints its exact version.
powershell
py install 3.14
py -3.14 --version

Expect a version beginning with Python 3.14.. If you already have Python 3.12 or newer, you can use that installation. Replace py -3.14 below with the command that reported your version. If py install is treated as a filename, use pymanager install 3.14 with the install manager.

Create your workspace

Choose a directory where you keep projects. Run these commands there. If the folder already exists, start with the second command.

powershell
mkdir python-study
cd python-study
py -3.14 -m venv .venv
.\.venv\Scripts\python.exe -c "import sys; print(sys.executable); print(sys.prefix != sys.base_prefix)"

The first output line ends in .venv\Scripts\python.exe. The second is True. This explicit interpreter path works in PowerShell even when script activation is restricted.

Save and run a script

From the project folder, type notepad hello.py. Create the file if prompted, enter the single line below, then save.

python
print("Python is ready")
powershell
.\.venv\Scripts\python.exe hello.py

You should see Python is ready. If the file cannot be found, run dir hello*. If its name is hello.py.txt, use Save As, choose All files, and save it as hello.py.

Continue to the first local project. Windows installation reference

Check your understanding

In PowerShell, which command runs hello.py with the Python launcher?

Choose one answer

Search documentation

Share this page