Is it possible to switch from Appium Driver to Android Driver

Hi All,

Is it possible Appium Driver to Android Driver, I am using Appium driver for running my Android tests but then I need to do scrolling which would require UIScrollable which is not possible with Appium driver.

Is it possible to cast the driver at run time? Let me know if some one has done.


@Venkatesh no issue you can change to AndroidDriver driver And then you will get the option

Have you managed to resolve your problem, I would like to hear if it is working and how you implemented switching?
Also, I didn’t know that Appium Driver doesn’t support UIscrollable, so good to know that and thanks.

You should be able to cast your driver and use UIScrollable.

AndroidDriver driver = (AndroidDriver)driver;

If this doesn’t work for whatever reason (like your driver is actually an IOSDriver) this will throw an error.


This does not works throws
java.lang.ClassCastException: io.appium.java_client.AppiumDriver cannot be cast to

I need to use methods like isKeyboardShown()

Added this as a suggestion to java client git

Did you solved the problem?

I have the same issue here.