Fixing Selenium error – session not created: This version of ChromeDriver only supports Chrome version 84

Selenium error – session not created: This version of ChromeDriver only supports Chrome version 84 is an error which occurs because of compatibility problems between ChromeDriver and Chrome or sometimes because of a faulty ChromeDriver installation.

In the blog post I attempt to explain why this error takes place and how you can solve it, I will also add other solutions that could solve the error if possible.

Exploring the Selenium error – session not created: This version of ChromeDriver only supports Chrome version 84

This is an error which occurs because of compatibility problems between ChromeDriver and Chrome or sometimes because of a faulty ChromeDriver installation.

The error should look like this. Double check in order to avoid mixing between errors.

                                                                       #
Traceback (most recent call last):
.....
selenium.common.exceptions.SessionNotCreatedException: Message: session not created: This version of ChromeDriver only supports Chrome version 84
                                                                       #

Bellow we will take care of the error using multiple possible solutions according to your needs.

Solution 1 : use webdriver-manager with Selenium instead

The error can be solved by using webdriver-manager instead. You can do that by installing it with the command bellow and then importing it and using it in your project.

                                                                       #
pip install webdriver-manager
                                                                       #

import and use webdriver-manager in your project like in the example bellow

                                                                       #
# example that gets http://www.twitter.com using webdriver-manager
from selenium import webdriver
from webdriver_manager.chrome import ChromeDriverManager
driver = webdriver.Chrome(ChromeDriverManager().install())
driver.get("http://www.twitter.com")
                                                                       #

using webdriver-manager instead of ChromeDriver only should solve your problem. if that is not the case try using the solution bellow.

Solution 2 : solve ChromeDriver compatibility issues with chrome

If you do not want to use webdriver-manager. You should fix the compatibility problems between chrome and ChromeDriver manually. Since your chrome version and ChromeDriver version need to be the same you need to accordingly downgrade or upgrade one of them or both sometimes.

This is simple on chrome you can use the UI to know which version you have by navigating to help and to the about section.

The solutions above should be enough to solve the problem, if you like our effort make sure to consider donating to our Kofi account, there is a red button that you can use if you are feeling generous.

Summing-up

The error above can be very confusing. The fix is simple and works for most cases, thank you for reading and cheers.

If you want to learn more about Python, please check out the Python Documentation : https://docs.python.org/3/