What You Need
| Item | Notes |
|---|---|
| Python 3.10 or newer | Recent Selenium releases dropped older versions. Download from python.org |
| A browser | Google Chrome is easiest for beginners. Firefox and Edge also work |
| Code editor | VS Code (free) or PyCharm Community (free) |
| Internet | Selenium Manager downloads drivers on first run |
Step 1: Check Python
You should see Python 3.10 or higher. On Windows tick Add Python to PATH during installation.
Step 2: Create a Project Folder and Virtual Environment
A virtual environment keeps the packages of one project separate from other projects.
When active, your terminal prompt shows (.venv).
Step 3: Install Selenium and pytest
Create a file requirements.txt so others can install the same packages:
Step 4: Verify the Installation
Step 5: Quick Browser Test
A Chrome window opens, loads the site, prints the title and closes. If this works your setup is complete.
Common Problems and Fixes
| Problem | Fix |
|---|---|
ModuleNotFoundError: No module named 'selenium' | Activate the virtual environment, then pip install selenium. In your editor select the .venv interpreter |
'python' is not recognized | Reinstall Python with *Add to PATH*, or use py on Windows |
| Driver download fails | Check internet or proxy settings. Corporate networks may block downloads; set HTTPS_PROXY |
| Version mismatch errors from an old driver | Remove old chromedriver from your PATH and let Selenium Manager choose |
| Script runs but window closes at once | That is normal: the script ended. driver.quit() closes the browser. Add input() to pause while learning |
Suggested Folder Structure
Conclusion
Install Python, create a virtual environment, run pip install selenium pytest and open a browser from a short script. Selenium Manager handles the driver for you.

