Capabilities Reference
Selenium capabilities
Capability | Values |
---|---|
browserName Browser you want to test. |
Firefox, Chrome, Internet Explorer, Safari, Opera, Edge, iPad, iPhone, Android Default: Chrome |
browserVersion Browser version you want to test. |
View list of browser versions to update this field. Default: Latest stable version of browser selected. |
acceptSslCerts Use this capability to ignore invalid certificate error in your test. |
true, false Default: false |
Browserstack-specific capabilities
Capability | Values |
---|---|
os OS you want to test. |
Windows, OS X |
osVersion OS version you want to test. |
Windows: XP, 7, 8, 8.1 and 10 OS X: Snow Leopard, Lion, Mountain Lion, Mavericks, Yosemite, El Capitan, Sierra, High Sierra, Mojave |
Test configuration capabilities:
Capability | Values |
---|---|
projectName Allows the user to specify a name for a logical group of builds. |
Example: loginformproject Default: Untitled Project |
buildName Allows the user to specify a name for a logical group of tests. |
Example: build 4.5 Default: Untitled Build |
sessionName Allows the user to specify an identifier for the test run. |
Example: logintest |
local Required if you are testing against internal/local servers. |
true, false Default: false |
localIdentifier Use this capability to specify the unique Local Testing connection name in your test. |
String Example: local_connection_name |
debug Required if you want to generate screenshots at various steps in your test. |
true, false Default: false |
consoleLogs Required if you want to capture browser console logs at various steps in your test. Console Logs are available for Selenium tests on Desktop Chrome, Desktop Firefox, Mobile Chrome (Android devices) and Mobile Safari (iOS devices). |
disable, errors, warnings, info, verbose Default: errors disable: stops capturing the console logs errors: shows only error output in console warnings: shows warning and error output in the console info: shows info statement, warning and error output in the console verbose: shows all console output |
networkLogs Required if you want to capture network logs for your test. Network Logs are supported for all desktop browsers, Android and iOS devices with a few exceptions - IE 10 on any OS; IE 11 on Windows 7 / 8.1 and any browser on MacOS High Sierra and Mojave. |
true, false Default: false Note: You may experience minor reductions in performance when testing with Network Logs turned on with Desktop sessions. |
appiumLogs Required if you want to capture raw appium logs for your test. |
true, false Default: true |
video Required if you want to enable video recording during your test. |
true, false Default: true |
seleniumLogs Required if you want to enable selenium logs for your desktop browser tests. |
true, false Default: true |
geoLocation Required if you want to test how your website behaves in specific countries. |
"CN" for China, "FR" for France, "IN" for India and "US" for United States of America Note: Complete list of of over 40+ countries can be found here. |
timezone Required if you want to configure tests to run on a custom time zone. |
New_York (for America/New_York), Los_Angeles (for America/Los_Angeles), La_Rioja (for America/Argentina/La_Rioja) Note: You can view the complete list of timezones on Wikipedia. |
resolution Set the resolution of VM before beginning of your test. |
Windows (XP,7): 800x600, 1024x768, 1280x800, 1280x1024, 1366x768, 1440x900, 1680x1050, 1600x1200, 1920x1200, 1920x1080, 2048x1536 Windows (8,8.1,10): 1024x768, 1280x800, 1280x1024, 1366x768, 1440x900, 1680x1050, 1600x1200, 1920x1200, 1920x1080, 2048x1536 OS X: 1024x768, 1280x960, 1280x1024, 1600x1200, 1920x1080 Default: 1024x768 |
seleniumVersion Use this capability to set the Selenium WebDriver version in test scripts. |
"3.7.0", "3.7.1", "3.8.0", "3.8.1", "3.9.0", "3.9.1", "3.10.0", "3.11.0", "3.12.0", "3.13.0", "3.14.0", "3.141.0", "3.141.5", "3.141.59", "4.0.0-alpha-1", "4.0.0-alpha-2" Note: Latest jar might not be compatible with older browsers. |
browserstack.maskCommands Use this capability to mask the data sent or retrieved by certain commands. Note: You can pass multiple commands in a single array, separated by commas. |
Default: Empty Array setValues All the text send via sendKeys command will be redacted. getValues All the text retrieved via get command will be redacted. setCookies All the cookies which are set by the addCookie command will be redacted. getCookies All the cookie values obtained using the getCookies and getCookieNamed command will be redacted. Example: browserstackOptions.put("maskCommands", "setValues, getValues, setCookies, getCookies");Note: Sensitive data in certain logs (like Selenium, Appium, video, etc.) cannot be masked. View our documentation to disable these logs instead. |
Mobile capabilities:
Capability | Values |
---|---|
deviceName Specifies a particular mobile device for the test environment. |
You can find a full list of supported devices here |
realMobile Use this flag to test on a physical mobile device. |
true, false Default: false Real Android devices are now available for Automated testing. View Documentation |
appiumVersion Use this capability to set the Appium version in your test scripts. |
Android: 1.6.5 (default), 1.7.1 , 1.7.2 , 1.8.0 , 1.9.1 , 1.10.1 , 1.11.1 , 1.12.1 , 1.13.0 , 1.14.0 , 1.15.0 iOS: 1.6.5 , 1.7.0 (default), 1.7.1 , 1.7.2 , 1.8.0 , 1.9.1 (default on iOS 12), 1.10.1 , 1.11.1 , 1.12.1 , 1.13.0 , 1.14.0 (default on iOS 13) Note: All values are strings. |
os OS you want to test. |
ios, android |
deviceOrientation Set the screen orientation of mobile device. |
portrait, landscape Default: portrait |
customNetwork Required if you want to simulate the custom network condition. |
Example ('1000', '1000', '100', '1') download speed (kbps), upload speed (kbps), latency (ms), packet loss (%) |
networkProfile Required if you want to simulate different network conditions. |
Example: 2g-gprs-good, 2g-gprs-lossy, 3g-umts-good etc. Complete list of network profiles can be found here. |
Chrome specific capabilities:
Capability | Values |
---|---|
driver Use this capability to specify the chromedriver version. |
The supported values are "2.43", "2.44", "2.45", "2.46", "73.0.3683.68", "74.0.3729.6", "75.0.3770.8", "75.0.3770.90", "75.0.3770.140", "76.0.3809.68", "77.0.3865.40", "78.0.3904.70", "79.0.3945.16". |
IE/Edge capabilities:
Capability | Values |
---|---|
IE noFlash Use this capability to disable flash on Internet Explorer. |
true, false |
IE compatibility Use this capability to set Internet Explorer Compatibility View. |
The supported values are 11001, 11000, 10001, 10000, 9999, 9000, 8888, 8000 and 7000. Refer to this Internet Explorer documentation for an explanation on these values. |
IE arch Use this capability to specify the IE WebDriver architecture. |
The supported values are "x32" for 32-bit and "x64" for 64-bit. |
IE driver Use this capability to specify the IE WebDriver version. |
The supported values are "3.13.0", "3.14.0", "3.141.0", "3.141.5", "3.141.59". |
IE enablePopups Use this capability to enable the popups in IE. |
true, false |
Edge enablePopups Use this capability to enable the popups in Edge. |
true, false |
browserstack.sendKeys Set the capability to ‘True’ while using sendKeys on IE 11 browser. |
true, false Default: false Example: capabilities.setCapability("browserstack.sendKeys", "true"); Note: Refer to the complete documentation here. |
Safari capabilities:
Capability | Values |
---|---|
enablePopups Use this capability to enable the popups in Safari. |
true, false |
allowAllCookies Use this capability to enable all cookies in Safari. |
true, false |
driver Use this capability to specify the Safari WebDriver version. |
"2.45", "2.48" |
Firefox and Gecko driver capabilities:
Capability | Values |
---|---|
driver Use this capability to specify the version of geckodriver. |
"0.20.0", "0.20.1", "0.21.0", "0.22.0", "0.23.0", "0.24.0" |
Parameter override rules
- osVersion can only be defined when os has been defined.
- Default browser is chrome when no browser is passed by the user or the selenium API (implicitly).
- If consoleLogs is enabled it will take precedence over Logging Preferences of type BROWSER that you may have set in your test script