try { driver.findElement(MobileBy.AndroidUIAutomator("new UiScrollable(new UiSelector().scrollable(true).instance(0)).scrollToEnd(10)")); Thread.sleep(1000); } catch (InterruptedException e) { // Handle the exception e.printStackTrace(); } ////up try { driver.findElement(MobileBy.AndroidUIAutomator("new UiScrollable(new UiSelector().scrollable(true).instance(0)).scrollToBeginning(10)")); Thread.sleep(1000); } catch (InterruptedException e) { // Handle the exception e.printStackTrace(); }