You need EdgeDriver to run Selenium tests in Microsoft Edge browser. It lets Selenium WebDriver interact with MS Edge browser just like a real user.

Here is a step-by-step guide to download, install, and set up the right version of EdgeDriver.

Step 1: Check Your Microsoft Edge Version

Before downloading EdgeDriver, you must check your Edge browser version.

Here’s how to check:

  • Open Microsoft Edge.
  • Click the three dots (⋮) at the top right corner - Select Help and Feedback - Select About Microsoft Edge. My version is Version 133.0.3065.92.
  • Update if you are using an older version. Note the version number (e.g., 133.x.x.x).
Check microsoft edge browser version

Why does this matter?

Many people keep complaining that the edge driver is not working in Selenium. The reason is EdgeDriver version updates with a version of the Edge browser, and a mismatch in versions can generate errors when you run Selenium tests.

Now let’s see how to download the correct version of EdgeDriver.

Are you looking to run selenium tests in Firefox browser? Here is a step-by-step guide on how to download and set up GeckoDriver for Selenium.

Step 2: Download EdgeDriver For Selenium WebDriver

To download EdgeDriver, follow these simple steps:
Download Edge Driver

Now let's see how to set up the edge driver.

Step 3: Extract and Set Up EdgeDriver

Once downloaded, you need to extract the ZIP file.
  • Extract the EdgeDriver ZIP file to a location like D:\WebDriver\
  • Inside the folder, you’ll find msedgedriver.exe.
But to run EdgeDriver in your selenium tests, you need to add it to the system PATH.

Here’s how:
  • Search for Environment Variables in Windows.
  • Under System Variables, find Path and click Edit.
  • Click New, then paste your folder path (e.g., D:\WebDriver\).
  • Click OK and restart your computer.
Now, EdgeDriver is ready to run.

Step 4: Run EdgeDriver with Selenium

To make sure EdgeDriver is working, let’s write a quick Selenium test script. Use the given edge driver set up code in your selenium test and run it. 

Example of Microsoft Edge Driver in Selenium
        // Set the path to EdgeDriver (only needed if it's not in system PATH)
        System.setProperty("webdriver.edge.driver", "D:\\WebDriver\\msedgedriver.exe");

        // Initialize EdgeDriver
        WebDriver driver = new EdgeDriver();
This example script will help you run the Selenium test on Microsoft Edge browser. Now, you can:
  • Open Edge automatically when running the Selenium test.
  • Navigate to websites.
  • Extract page titles & interact with web elements.
Tip: Always use the latest Selenium version and update EdgeDriver whenever Edge browser's version updates.

Are you looking to automate Firefox with Selenium WebDriver? You need GeckoDriver.

But many beginners struggle with setting it up correctly.

If that’s you, don’t worry. 

Let's see how to download and use geckodriver in selenium test step by step.

What is GeckoDriver? (And Why Do You Need It?)

Simply put, GeckoDriver acts as a bridge between Selenium and Firefox. Without it, your automation test scripts will not work in the Firefox browser.

That is the reason you need to install it before running Selenium WebDriver with Java.

Now, let’s get started.

Selenium WebDriver is a popular & widely used web browser automation tool that automates web application testing in all major browsers and operating systems. This remote-control open-source API allows you to create and execute automation tests natively in browsers using multiple supported programming languages.

History of Selenium WebDriver

Selenium and WebDriver were created by distinct individuals, but in the end, they became one powerful automation tool.

Before moving ahead, we should quickly examine the history of Selenium and WebDriver's development.

Selenium:

Development:

Initially, Selenium was designed and developed by Jason Huggins in 2004 when he was working at ThoughtWorks in Chicago.

Primarily, he developed it to automate web application testing. 

Later on, Paul Hammant, Aslak Hellesoy, Mike Melia, Aslak, and Obie Fernandez joined him.

They worked collectively to develop and improve different components of Selenium, like the server and client driver, and make it an open source framework.