# Virtual Environment

*noun*

say it: **“VER-choo-ul en-VY-run-ment”** **/ˈvɜːrtʃuəl ɛnˈvaɪrənmənt/**

A private folder of installed Python packages for one project, made with python -m venv, so projects that need different versions don't get in each other's way.

## What is a **virtual environment**?

A **virtual environment** is a private folder of installed packages for one project, so projects that need different versions don't get in each other's way.

```bash
python -m venv .venv          # create it
.venv\Scripts\activate        # Windows (macOS/Linux: source .venv/bin/activate)
pip install requests          # installs into this project only
```

## In a sentence

- “Activate the **virtual environment** so pip installs into this project only.”
- “She made a **virtual environment** in .venv before installing pytest.”

Level: Journeyman · [More Python terms at this level](https://www.ask-codey.com/glossary?category=python&level=3)

Updated: November 19, 2026

Source: https://www.ask-codey.com/glossary/virtual-environment
