SeleniumLab

Course1 · Selenium automation → Getting Started

1 · Selenium automation

Install Selenium and WebDriver

8 min · Module 6

Selenium drives real browsers so you can automate clicks, typing, and checks against a live site.

  1. Create and activate a virtual environment.
  2. Install the library: pip install selenium.
  3. Modern Selenium can manage ChromeDriver for you via Selenium Manager.

Keep your Django practice lab running at http://127.0.0.1:8000 while you experiment.

Example / notes

from selenium import webdriver
from selenium.webdriver.chrome.options import Options

options = Options()
# options.add_argument("--headless=new")  # optional

driver = webdriver.Chrome(options=options)
driver.get("http://127.0.0.1:8000/lab/")
print(driver.title)
driver.quit()

Practice in Lab: /lab/

Log in to track progress / take quizzes
Your first automation script →
Modules in this track