'The type org.openqa.selenium.firefox.FirefoxDriver is not accessible
I need help in setting up selenium in MAC OS. I have added all the required selenium jar files and java JRE to build path. I have added java path in .profile But still I am still getting error for Firefox driver.
The type org.openqa.selenium.firefox.FirefoxDriver is not accessible
Can you please help.

Solution 1:[1]
To resolve this issue,
- create a new Java project with JRE syetm libraray (JavaSE 1.8)
- copy jar file and build path
- copy driver executables
Create new class and move on with your work!!!
Solution 2:[2]
This error message...
The type org.openqa.selenium.firefox.FirefoxDriver is not accessible
...implies that the GeckoDriver was not accessible by your program/script,
Your main issue is the presence of numerous unwanted JAR files containing the same class which are:
- selenium-server-standalone-3.14.0.jar
- Selenium-Java client JARs.
- selenium-firefox-driver-2.35.0.jar
Solution
- Remove all the JARs and add back only selenium-server-standalone-3.14.0.jar
Download the required format of GeckoDriver executable from mozilla/geckodriver, extract the binary and then initialize the FirefoxDriveras follows:
//imports import org.openqa.selenium.WebDriver; import org.openqa.selenium.firefox.FirefoxDriver; //other lines of code System.setProperty("webdriver.gecko.driver","C:\\path\\to\\geckodriver.exe"); driver = new FirefoxDriver(); driver.get("https://www.google.com/");
Solution 3:[3]
From what I can see in your 'Referenced Libraries' folder, you seem to have added both the selenium-standalone-3.x.x.jar and the individual client-combined-3.x.x versions of the jar files (selenium client jars for java). Is it possible that your eclipse does not know which libraries to finally use? Request you to remove all the libraries in your build path and add ONLY the selenium-server-standalone-3.x.x.jar file. Once done, refresh and this should resolve.
Also, once the right jars are in place, the import should resolve even without the System.setProperty instruction in your class file.
If the issue persists, could you please paste a screen capture without the right-click context menu on the error? Hope this helps.
Solution 4:[4]
The pretty simple solution is " You might have created module while creating the package. So simply delete the module it will resolve the issue. It worked for me!!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Karol Dowbecki |
| Solution 2 | undetected Selenium |
| Solution 3 | Stephen |
| Solution 4 | J Vinay |
