MirrorNest
← Todas las guías

Python development environment on Windows

Install Python via winget and set up an isolated virtual environment per project -- the standard, officially recommended way to avoid dependency conflicts between projects.

Sistema: Windows 10 2004+ or Windows 11DevelopmentProgrammingSitio oficial ↗Documentación oficial ↗
Esta guía se elaboró a partir de la documentación oficial de Python development environment on Windows, enlazada arriba — verifica siempre ahí los nombres exactos de paquetes/versiones antes de ejecutar estos comandos en un servidor de producción, ya que las versiones de la distribución y del proyecto cambian con el tiempo.
  1. 1Install Python via WinGet

    winget install --id Python.Python.3.12 -e

    Installing via winget (rather than the Microsoft Store listing) gets the official python.org build and avoids the Store version's sandboxing quirks.

  2. 2Verify the install in a new terminal

    Open a fresh PowerShell window (so PATH changes take effect) and confirm.

    python --version
    pip --version
  3. 3Create a virtual environment per project

    Run this inside your project folder -- it creates an isolated Python + pip just for that project, so its dependencies never clash with another project's.

    python -m venv .venv
    .venv\Scripts\Activate.ps1

    If PowerShell blocks the activation script with an execution-policy error, run: Set-ExecutionPolicy -Scope CurrentUser RemoteSigned

  4. 4Install packages into the active environment

    pip install --upgrade pip
    pip install <package-name>