---
source_url: "https://www.browserstack.com/docs/app-automate/appium/integrations/katalon-studio"
title: "Run Appium tests using Katalon Studio | BrowserStack Docs"
mirrored_at: 2026-08-13T01:33:59.653Z
host: www.browserstack.com
cited_in_42a: true
mirror_canonical: "https://index.42a.ai/www.browserstack.com/docs/app-automate/appium/integrations/katalon-studio"
---

> **Original source:** https://www.browserstack.com/docs/app-automate/appium/integrations/katalon-studio

Run your automated app tests on Appium using Katalon Studio. Execute automated tests on thousands of real iOS and Android devices offered by BrowserStack.

Katalon Studio allows you to set up, create, and manage automated mobile tests. With BrowserStack and Katalon, you can execute your automated tests on a range of real devices offered by BrowserStack.

Select the platform you want to test on:

-   [Android](#Android)
-   [iOS](#iOS)

Download **Katalon Studio** by signing up for a free account at [Katalon’s website](https://www.katalon.com/sign-up/). After installation, log in to Katalon Studio using your account credentials and create a new Sample Android Mobile Tests Project. This process uses the sample app and test cases provided by Katalon. You can replace them with your own app and test cases.

![Creating new sample Android Mobile Tests Project](https://www.browserstack.com/docs/static/img/appium/app_profiling/sample_project.webp)

Set the project name in the **Name** field and click **OK**.

![Set the project name in name field and press OK](https://www.browserstack.com/docs/static/img/appium/app_profiling/name.webp)

In the **Tests Explorer** window, go to the folder **androidapp → APIDemos.apk**. This is the application that will be tested on BrowserStack.

![Tests Explorer](https://www.browserstack.com/docs/static/img/appium/app_profiling/test_explorer.webp)

### Upload app on the BrowserStack server

To learn how to upload your apps to BrowserStack devices and manage them, refer to the [upload and manage apps](https://www.browserstack.com/docs/app-automate/appium/set-up-test-env/upload-and-manage-apps) section. For example, to upload `APIDemos.apk` to BrowserStack with the REST API using your account credentials:

The following is a sample response:

After the app uploads successfully, BrowserStack returns an `app_url`. This is the unique hashed ID of your uploaded app.

### Configure the tests

In the **Tests Explorer** section in Katalon Studio, go to **Test Cases** and open the test case named **Verify Last Items In List** in the script view. Replace the highlighted portion of the code as shown below:

![Verify Last Items In List](https://www.browserstack.com/docs/static/img/appium/app_profiling/last_items_in_list.webp) Make the following changes to the code:

Replace this code:

With this code:

You must also import a few additional packages:

This is the resultant script:

![Resultant script](https://www.browserstack.com/docs/static/img/appium/app_profiling/result.webp)

You can also replace the existing code in **Verify Last Items In List** with the [sample test script](https://gist.github.com/ashwingonsalves/5ad2827b0fc3f83d5e02aed4f0997f49) and execute it. Update the following details in the script:

1.  Add your USERNAME and ACCESS\_KEY.
2.  Add the `app_url` (`bs://<hashed-id>`) returned for the uploaded Android app.

Execute the test by clicking the play icon and visit the [App Automate Dashboard](https://app-automate.browserstack.com/) to see your session running on BrowserStack.

Download **Katalon Studio** by signing up for a free account at [Katalon’s website](https://www.katalon.com/sign-up/). After installation, log in to Katalon Studio using your account credentials and create a new **Sample iOS Mobile Tests Project**. This process uses the sample app and test cases provided by Katalon. You can replace them with your own app and test cases.

![Creating new sample iOS Mobile Tests Project](https://www.browserstack.com/docs/static/img/appium/app_profiling/ios_sample_project.webp)

Set the project name in the **Name** field and click **OK**.

![Setting project name in Katalon Studio](https://www.browserstack.com/docs/static/img/appium/app_profiling/ios_project_name.webp)

In the **Tests Explorer** window, go to the folder **App → Coffee Timer-iPad Pro (9.7-inch).ipa**. This is the application that will be tested on BrowserStack.

![Katalon IOS Test Select Coffee Timer-iPad Pro (9.7-inch).ipa file](https://www.browserstack.com/docs/static/img/appium/app_profiling/ios_test.webp)

### Upload app on the BrowserStack server

To learn how to upload your apps to BrowserStack devices and manage them, refer to the [upload and manage apps](https://www.browserstack.com/docs/app-automate/appium/set-up-test-env/upload-and-manage-apps) section. For example, to upload `Coffee Timer-iPad Pro (9.7-inch).ipa` to BrowserStack with the REST API using your account credentials:

The following is a sample response:

After the app uploads successfully, BrowserStack returns an `app_url`. This is the unique hashed ID of your uploaded app.

### Configure the tests

In the **Tests Explorer** section in Katalon Studio, go to **Test Cases** and open the file named **Verify the main list** in the script view. Replace the highlighted portion of the code as shown below:

![Replace the highlighted portion of the code in the script](https://www.browserstack.com/docs/static/img/appium/app_profiling/ios_verify.webp)

Make the following changes to the code.

Replace this code:

With this code:

You must also import a few additional packages:

This is the resultant script:

![How to use MobileDriverType while creating driver](https://www.browserstack.com/docs/static/img/appium/app_profiling/mobile_driver_type.webp)

You can also replace the existing code in the **Verify the main list** with the [sample test script](https://gist.github.com/ashwingonsalves/cea349a6d257eb28c19540f63a952318) and execute it. Update the following details in the script:

1.  Add your USERNAME and ACCESS\_KEY.
2.  Add the `app_url` (`bs://<hashed-id>`) returned for the uploaded iOS app.

Execute the test by clicking the play icon and visit the [App Automate Dashboard](https://app-automate.browserstack.com/) to see your session running on BrowserStack.

## Set session and build names

By default, BrowserStack labels each session and build automatically. You can set your own names to organize your tests on the App Automate dashboard. Choose one of the following approaches based on when the names are known.

### Set names when you create the driver

If the session and build names are known before the test runs, set them as capabilities in the same block where you create the driver:

### Set names dynamically from a Test Suite Listener

To name a session after the test case that produced it, you need the test case name and status at runtime. A Test Suite Listener exposes these through the `TestCaseContext` object, but the naming must happen after the session exists.

In Katalon Studio, the Appium driver is created only when a driver-starting step runs inside the test case body, such as `AppiumDriverManager.createMobileDriver()` or `Mobile.startApplication()`. Calling `MobileDriverFactory.getDriver()` inside the `@BeforeTestCase` method of a Test Suite Listener runs before the driver exists and fails with `StepFailedException: No application is started yet`. Read the driver from `@AfterTestCase` instead, after the test case has started the session.

Implement the listener in one of the following two ways. Both read the driver in `@AfterTestCase`, so register only one of them.

The first approach updates the session from the `@AfterTestCase` method using the [BrowserStack REST API](https://www.browserstack.com/docs/app-automate/api-reference/appium/sessions#update-session-name). At this point the test case has already started the session, so you can read its ID from the driver and send the runtime name and status:

The second approach updates the session with the `browserstack_executor` JavaScript executor instead of the REST API. Because the session is still active when `@AfterTestCase` runs, this keeps your username and access key out of the listener:

Ensure the test case does not close the app as its final step:

-   If the last step is `Mobile.closeApplication()`, which Katalon sample tests often use, the driver is already quit by the time `@AfterTestCase` runs.
-   `MobileDriverFactory.getDriver()` then throws the same `StepFailedException`, and the update silently falls into the catch block.
-   Remove the closing step from the test case body, as Katalon tears down the driver after listeners run anyway.

Register the listener in your project so that it runs for every test case. Katalon runs `@AfterTestCase` once per test case, so each session is named after the test case that created it.

Did this page help you?

#### We're sorry to hear that. Please share your feedback so we can do better

Contact our [Support team](https://www.browserstack.com/support) for immediate help while we work on improving our docs.

#### We're continuously improving our docs. We'd love to know what you liked

-   This page has exactly what I am looking for  
    
-   This content & code samples are accurate and up-to-date  
    
-   The content on this page is easy to understand  
    
-   Other (please tell us more below)  
    

Any additional feedback?

Thank you for your valuable feedback