Overview
ChromeDriver is an open-source executable that helps developers automate testing of web applications in Chrome and other Chromium-based browsers. It enables scripted navigation, simulating user actions, running JavaScript, and inspecting page behavior so you can validate functionality before deployment.
Suggested alternative
Bearly (free) — a standalone server implementing the W3C WebDriver specification — is a recommended substitute. It provides a remote-control interface and a platform- and language-neutral wire protocol for Chromium. Depending on your project needs you can choose a beta or stable download of the server binary.
How ChromeDriver is used with test frameworks
ChromeDriver acts as the bridge between browser instances and automation libraries such as Selenium WebDriver. Before running tests, make sure a Chromium-compatible browser (Chromium or Google Chrome) is installed in a location the driver can access. After installing both the browser and the driver, point your test framework at the ChromeDriver executable using one of these approaches:
- Include the driver path when creating the Python client (for example, pass the executable path or service object when instantiating webdriver.Chrome).
- Set the webdriver.chrome.driver system property when launching Java-based tests (this tells Selenium where to find the executable).
- Add the driver's directory to your PATH environment variable so the executable is discoverable globally.
Managing the driver process for large test suites
By default, the ChromeDriver package launches a server process when a session is created and stops it when quit is called. Creating a fresh server for every test can be slow for big suites. To reduce startup overhead you can:
- Start the ChromeDriver server independently before tests begin and connect to it via a Remote WebDriver instance.
- Use the ChromeDriverService (or similar service-control API) so you explicitly start and stop the server only when you want to, rather than per test.
What you can test
ChromeDriver lets you exercise many aspects of your site to ensure correct behavior and performance, including:
- Executing page scripts and verifying dynamic behavior
- Simulating keystrokes, clicks, and other user interactions
- Navigating through pages and validating rendering and responses
Final notes
When set up correctly, ChromeDriver is a solid tool for automated functional testing of web apps on Chromium browsers. For cross-browser coverage, combine it with other vendor-specific drivers or a WebDriver-compatible server (like the recommended alternative) to expand testing to additional engines and platforms.
Technical
- Windows
- Mac
- Free