Skip to main content

Appium Server Supported Capabilities

Capabilities

CapabilityDocumentationSupported OSComments
uniqueNameApplication SetupiOS/AndroidInstall and launch an app with a unique name.
reportDisable (report.disable)Automated Test ReportsiOS/AndroidEnable or disable report generation.
installOnlyForUpdateApplication SetupiOS/AndroidRe-installs an app only if an older version already exists on the device.
buildVersion / releaseVersion / appVersionApplication SetupiOS/AndroidInstall and launch the app by build version or release version.
instrumentAppApplication SetupiOS/AndroidInstrument the app—required for additional capabilities (e.g., simulateCapture).
DeviceQueryDevice SetupiOS/AndroidUse device queries for cloud devices instead of the udid capability.
appiumVersionAppium Version CapabilityiOS/AndroidSelect the Appium Server version for the execution.
releaseDeviceDevice SetupiOS/AndroidPrevents releasing the device after driver.quit().

Default: true

No effect if the device is already reserved or part of a future reservation.
dontGoHomeOnQuitiOS/AndroidKeeps the device in the last active state after the test ends.

Default: false

iOS: For a new session, launch the app with noReset=true (Appium 1.22.0+).
commandScreenshotiOS/AndroidVideo Report: Capture screenshots before and after each action.

Default: false
AudioReportAttaching Audio to Video ReportiOS/AndroidAttach device audio to the video report.
selfHealingAppium Self-HealingiOS/AndroidEnable or disable self-healing during a session.

Default: false
otherAppsiOS/AndroidAdditional apps to install before running tests.
appiumPluginsAppium Server PluginsiOS/AndroidPlugin or list of plugins to use during the Appium server session.
skipSafariCleanupiOSSkip Safari cache clean-up before Appium tests.
Default: false
acceptInsecureCertsiOS/AndroidAccept or ignore insecure certificates.
Default: false
AcceptInsecureCertsTestsiOS/AndroidacceptInsecureCerts=false: Webpage shows This Connection Is Not Private.

acceptInsecureCerts=true: Browser auto-trusts the site and navigates normally.

Note: Running true → false tests back-to-back might cause the browser to remember the trusted state, preventing the SSL warning from reappearing and causing occasional test failures.

Code Examples

info

Replace <server> with the appropriate URL.

iOS Native Test 

          protected AppiumDriver<MobileElement> driver = null;//driver
DesiredCapabilities dc = new DesiredCapabilities();

@Before
public void setUp() throws MalformedURLException {
//Appium Open Source Have to capabilities
dc.setCapability("testName",<Your Test Name>);//set the test name
dc.setCapability("platformName", "iOS");//set platform(iOS/Android)
dc.setCapability("deviceName", "auto");//set the device name
dc.setCapability(MobileCapabilityType.AUTOMATION_NAME, "XCUITest");//automation name(XCUITest for iOS)
dc.setCapability(MobileCapabilityType.APP, <Your APP>);//for install


//Experitest capabilities
dc.setCapability("accessKey", <your accessKey>);// cloud Authorization
dc.setCapability("appiumVersion", <Appium Version>);//Desired Appium version for example 1.16.0-p1
driver = new IOSDriver<IOSElement>(new URL("<server>), dc);//init driver
}

@Test
public void Test(){
//Your Test Goes Here
}

@After
public void tearDown() {
driver.quit();

}

iOS Web Test 

        protected AppiumDriver<MobileElement> driver = null;//driver
DesiredCapabilities dc = new DesiredCapabilities();

@Before
public void setUp() throws MalformedURLException {
//Appium Open Source Have to capabilities
dc.setCapability("testName",<Your Test Name>);//set the test name
dc.setCapability("platformName", "iOS");//set platform(iOS/Android)
dc.setCapability("deviceName", "auto");//set the device name
dc.setCapability(MobileCapabilityType.AUTOMATION_NAME, "XCUITest");//automation name(XCUITest for iOS)
dc.setCapability(MobileCapabilityType.BROWSER_NAME, BrowserType.SAFARI);//for mobile web


//Experitest capabilities
dc.setCapability("accessKey", <your accessKey>);// cloud Authorization
dc.setCapability("appiumVersion", <Appium Version>);//Desired Appium version for example 1.16.0-p1
driver = new IOSDriver<IOSElement>(new URL("<server>), dc);//init driver
}

@Test
public void test()
{
driver.get("http://www.google.com");
//your test goes here
}


@After
public void tearDown(){

driver.quit();


}

Android Native Test 

protected AppiumDriver<MobileElement> driver = null;//driver
protected DesiredCapabilities dc = new DesiredCapabilities();
private String deviceSN = <device serial number>;//device to run on
private String appiumVersion = "1.16.0-p2";//appium version to run


@Before
public void before() throws MalformedURLException {
//Appium capabilities
dc.setCapability("udid", deviceSN);
dc.setCapability("testName", <your test name>);
dc.setCapability("app","cloud:" + <app-package>);
dc.setCapability("automationName", "UiAutomator2");
dc.setCapability("platformName", "Android");

//Experitest capabilities
dc.setCapability("accessKey", <your accessKey>);// cloud Authorization
dc.setCapability("appiumVersion", appiumVersion);//Appium server version
driver = new AndroidDriver<>(new URL("<server>), dc);
}

@Test
public void test() {
//your test goes here
}


@After
public void tearDownAfterAll() {
if (driver != null) {
driver.quit();
}
}

Android Web Test 

protected AppiumDriver<MobileElement> driver = null;//driver
protected DesiredCapabilities dc = new DesiredCapabilities();
private String deviceSN = <device serial number>;//device to run on
private String appiumVersion = "1.16.0-p2";//appium version to run


@Before
public void before() throws MalformedURLException {
//Appium capabilities
dc.setCapability("udid", deviceSN);
dc.setCapability("testName", <your test name>);
dc.setCapability(MobileCapabilityType.BROWSER_NAME, "Chrome");
dc.setCapability("automationName", "UiAutomator2");
dc.setCapability("platformName", "Android");

//Experitest capabilities
dc.setCapability("accessKey", <your accessKey>);// cloud Authorization
dc.setCapability("appiumVersion", appiumVersion);
driver = new AndroidDriver<>(new URL("<server>"), dc);
}

@Test
public void test() {
driver.get("https://www.experitest.com");

driver.findElement(By.id("to-about-section")).click();
driver.findElement(By.id("firstname")).sendKeys("user1");
driver.findElement(By.id("lastname")).sendKeys("last1");
driver.findElement(By.id("email")).sendKeys("myemail@company.com");
driver.findElement(By.id("password")).sendKeys("pass");
}


@After
public void tearDownAfterAll() {
if (driver != null) {
driver.quit();
}
}