Cannot Start The Driver Service On Http Localhost Selenium Firefox C [patched] -

– upgrade to latest: pip install -U selenium

) into the driver constructor that expects the path to the driver executable ( geckodriver.exe new FirefoxDriver(@"C:\Program Files\Mozilla Firefox") : Pass the directory containing geckodriver.exe – upgrade to latest: pip install -U selenium

If you prefer the "old school" way or cannot use NuGet packages due to corporate restrictions, you are likely manually downloading geckodriver.exe . If you are doing this, the error usually stems from the fact that the FirefoxDriver class cannot locate the file. – upgrade to latest: pip install -U selenium