Mobile Testing - Keeps getting error failed to start Appium in 10 seconds!

Caused by: com.kms.katalon.core.appium.exception.AppiumStartException: Fail to start Appium server in 10 seconds

   \[31m	at com.kms.katalon.core.appium.driver.AppiumDriverManager.startAppiumServerJS(AppiumDriverManager.java:227)\[39m

   \[31m	at com.kms.katalon.core.appium.driver.AppiumDriverManager.startAppiumServerJS(AppiumDriverManager.java:210)\[39m

   \[31m	at com.kms.katalon.core.appium.driver.AppiumDriverManager.startAppiumServerJS(AppiumDriverManager.java:454)\[39m

   \[31m	at com.kms.katalon.core.appium.driver.AppiumDriverManager.ensureServicesStarted(AppiumDriverManager.java:197)\[39m

   \[31m	at com.kms.katalon.core.appium.driver.AppiumDriverManager.createMobileDriver(AppiumDriverManager.java:626)\[39m

   \[31m	at com.kms.katalon.core.mobile.keyword.internal.MobileDriverFactory.startMobileDriver(MobileDriverFactory.java:510)\[39m

   \[31m	at com.kms.katalon.core.mobile.keyword.internal.MobileDriverFactory$startMobileDriver.call(Unknown Source)\[39m

   \[31m	at com.kms.katalon.core.mobile.keyword.builtin.StartExistingApplicationKeyword$\_startApplication_closure1.doCall(StartExistingApplicationKeyword.groovy:50)\[39m

   \[31m	at com.kms.katalon.core.mobile.keyword.builtin.StartExistingApplicationKeyword$\_startApplication_closure1.doCall(StartExistingApplicationKeyword.groovy)\[39m

   \[31m	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)\[39m

   \[31m	at com.kms.katalon.core.mobile.keyword.internal.MobileKeywordMain.runKeyword(MobileKeywordMain.groovy:30)\[39m

   \[31m	... 6 more\[39m

I keep getting this error before the test really runs. Maybe on the 3rd or 5th times it runs the test. Im using cucumber framework with Katalon SE.

This error occurs before Cucumber or the mobile test starts: Katalon is timing out while launching its local Appium server. Because it succeeds on the 3rd or 5th attempt, focus on an intermittent local Appium/Node/port/startup issue rather than the test script itself. Katalon’s troubleshooting documentation describes this class of error as Appium not starting within its configured timeout.

Recommended checks

  1. Capture the actual Appium startup error

    • In Katalon Studio, set Appium Log Level to Debug under Window > Katalon Studio Preferences > Katalon > Mobile.

    • Re-run once and inspect the generated .appium log in the project directory. The AppiumStartException wrapper alone does not show the root cause; the first underlying ERROR line in the Appium log is the important part.

  2. Check whether port 4723 is already occupied

    • A previous failed run may leave an Appium/Node process alive.

    • On Windows, run:

      netstat -ano | findstr :4723

    • If a process is listening on that port, identify it:

      tasklist /FI "PID eq <PID>"

    • Stop only the stale Appium/Node process if it belongs to the failed Katalon run, then retry. Do not blindly terminate unrelated Node processes.

  3. Verify the Node/Appium installation Katalon sees

    • From the same Windows user account that launches Katalon:
      where node
      node --version
      where appium
      appium --version

    • Multiple Node installations, especially Node Version Manager/NVM plus a system Node installation, can cause Katalon to find a different Node/Appium installation than the terminal does. Katalon community troubleshooting identifies that mismatch as a known cause of Appium-start failures.

  4. Confirm the Appium version is compatible with the Katalon version

    • Do not upgrade/downgrade Appium based only on generic internet guidance. Compatibility depends on the specific Katalon Studio release.

    • Recent community cases point to incompatible or incompletely installed Appium drivers as common causes

    • Share the exact Katalon Studio version, OS, Node version, Appium version, and whether it is Android or iOS before changing versions.

  5. For Android, confirm the device toolchain

    • Run:

      adb devices
      adb kill-server
      adb start-server
      adb devices

    • The device must appear as device, not unauthorized or offline.

    • Also confirm ANDROID_HOME/Android SDK paths and platform tools are available to the same user running Katalon. An unhealthy ADB connection can make startup intermittent.

About the “10 seconds” timeout

Katalon documents a configurable Appium-start timeout. Increasing it may help if Appium is genuinely slow to initialize, but it will not fix a port conflict, Node mismatch, missing driver, or permission problem. Therefore, get the debug .appium log first, then adjust the timeout only if the log shows normal startup completing just after 10 seconds

This happens before your Cucumber scenario starts—Katalon is timing out while starting the local Appium server. Since it works after several retries, I would first check for a stale Appium/Node process or port conflict, then inspect the Appium debug log for the actual cause.

Please enable Debug Appium logging in Window > Katalon Studio Preferences > Katalon > Mobile, reproduce the issue once, and share the generated .appium log from the project folder—especially the first ERROR after Appium starts. Also share your exact Katalon version, OS, Android/iOS target, Node version, and Appium version.

On Windows, check port 4723 with netstat -ano | findstr :4723. If a stale Appium process is holding it after a failed run, stop that process and retry. Also verify Katalon is using the intended Node/Appium installation with where node, node --version, where appium, and appium --version. Multiple Node installations can cause this failure.

Appium log:
[Appium] Welcome to Appium v3.7.0 (REV deac4e0932eb3031656cdcbe12f0a7be2cacb69f)
[Appium] Non-default server args:
[Appium] { basePath: ’/wd/hub’, loglevel: ’info’, port: 52125 }
[Appium] Attempting to load driver xcuitest…
[Appium] Attempting to load driver uiautomator2…
[Appium] Appium REST http interface listener started on http://0.0.0.0:52125/wd/hub
[Appium] You can provide the following URLs in your client code to connect to this server:
http://127.0.0.1:52125/wd/hub (only accessible from the same host)

http://192.168.8.192:52125/wd/hub

http://192.168.87.211:52125/wd/hub

[Appium] Available drivers:
[Appium] - xcuitest@12.8.0 (automationName ‘XCUITest’)
[Appium] - uiautomator2@8.5.0 (automationName ‘UiAutomator2’)
[Appium] No plugins have been installed. Use the “appium plugin” command to install the one(s) you want to use.

Try:

  1. Update Katalon Studio and its bundled Appium/Node dependencies, then restart the machine.
  2. Before running, stop stale node/appium processes and ensure the configured Appium port (commonly 4723) is free.
  3. In Project Settings → Desired Capabilities / Mobile, verify the Appium server path and port; avoid sharing the same port across parallel runs.
  4. If startup is intermittently slow, increase the Appium server startup timeout (if your KS version exposes it) or start Appium manually, wait until it is ready, then connect KS to that server.
  5. Check the Appium server log immediately before this stack trace—the real cause is normally there (for example port already in use, Node/Appium missing, permission issue, or device/SDK initialization delay).

Let us know how it goes

looking at your appium log there is actually no error in it, appium 3.7.0 starts fine and loads both xcuitest and uiautomator2. so this is not a broken install, it is just appium taking longer than the 10 seconds katalon waits before giving up. that also explains why it passes on the 3rd or 5th try, node cache is warm by then.

three things i would try:

  1. the 10 seconds is not hardcoded. katalon reuses the project’s “default wait for element timeout” (project > settings > execution) as the appium startup timeout, and yours is probably set to 10. bump it to 30 or 60 and the error should disappear. katalon docs mention this under “fail to start appium server in 30 seconds”.

  2. only keep the driver you actually use. loading xcuitest when you only test android (or the other way around) adds a few seconds every start. appium driver list then appium driver uninstall xcuitest for example.

  3. start appium yourself before the run (appium --base-path /wd/hub -p 4723) and point katalon to that running server instead of letting studio spawn it. then the startup limit never kicks in and you can also see the appium log live.

you can also time it with time appium --base-path /wd/hub -p 4723 and ctrl+c once it prints the listener line. if that is already around 8 to 12 seconds on your machine then it is confirmed.