Skip to main content

Install ChromeDriver and Match It with Chrome

· 2 min read
Apache Wangye
Software developer and technical writer

ChromeDriver connects Selenium to the Chrome browser. Most startup failures come from an incompatible browser/driver combination, an incorrect executable path, or a missing browser binary.

Record the versions of Chrome, ChromeDriver, Selenium, the operating system, and the CPU architecture when troubleshooting. Current Selenium releases can usually manage the driver automatically, which is preferable to maintaining a driver manually.

Check the Chrome version

Open the following page in Chrome:

chrome://settings/help

For older ChromeDriver releases, the browser and driver generally had to share the same major version. For current Chrome for Testing releases, use the official version-selection data instead of relying on an old three-part matching rule.

Download ChromeDriver

Use the official Chrome for Testing page:

https://googlechromelabs.github.io/chrome-for-testing/

Download the package for the correct operating system and architecture, extract it, and either add the executable directory to PATH or pass its path explicitly.

Verify with Selenium

With a modern Selenium version, Selenium Manager can resolve the driver automatically:

from selenium import webdriver

options = webdriver.ChromeOptions()
# Set this only when Chrome is installed in a non-standard location.
# options.binary_location = "/path/to/chrome"

driver = webdriver.Chrome(options=options)
try:
driver.get("https://www.example.com")
driver.maximize_window()
finally:
driver.quit()

For older Selenium versions, create a Service explicitly instead of using the deprecated executable_path argument:

from selenium import webdriver
from selenium.webdriver.chrome.service import Service

service = Service("/path/to/chromedriver")
driver = webdriver.Chrome(service=service)
driver.quit()

Common errors

  • Session not created: compare the installed Chrome major version with the selected driver.
  • Chrome binary not found: set options.binary_location to the actual browser executable.
  • Driver executable not found: fix PATH, file permissions, or the Service path.
  • Browser exits immediately: inspect ChromeDriver logs, sandbox restrictions, display availability, and container shared-memory limits.

Page views: --

Total views -- · Visitors --