Skip to main content
🚀 Self Healing AI Agent now live in App Automate! Auto-fix flaky tests instantly with zero code changes. Enable now!
No Result Found
Connect & Get help from 6000+ developers on our Discord community. Ask the CommunityAsk the Community

Run Appium tests using Nightwatch

Your guide to running tests using Nightwatch on BrowserStack’s Appium Grid of 3000+ real devices.

Run tests on 3000+ real devices and desktop browsers

In this document, you’ll learn how to set up your Nightwatch Appium testing environment, configure your test settings, and execute your first automated test on BrowserStack’s real device cloud. We’ll walk you through each step, from initial setup to viewing your test results on the dashboard.

Prerequisites

  • BrowserStack username and access key, which you can find in your profile settings. If you have not created an account yet, you can sign up for a free trial.
  • Node.js 14+ installed on your system. You can download the updated Node version from nodejs.org.

You can download and test using our sample Android app or sample iOS app.

Run a sample build

Here’s how you can run a sample Nightwatch test build in three steps on BrowserStack:

Clone the sample repository

Clone our sample repository and install the dependencies.

Terminal
Copy icon Copy

Set access credentials

Set userName and accessKey parameters using environment variables to authenticate your tests.

Copy icon Copy
Copy icon Copy
Copy icon Copy

Execute the build on BrowserStack

You are now ready to run your build on BrowserStack. From the root directory of this project (Android/iOS), run one of the following commands according to your requirements:

Copy icon Copy

If a test run stops due to a crash, you can stop the build from running by clicking the Stop build option from the App Automate dashboard.

Screenshot showing the Stop Running Tests button in the App Automate dashboard

Next Steps

Once you have successfully run the sample test on BrowserStack, check the following:

Need help?

If you have any queries, get in touch with us.

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

Contact our Support team for immediate help while we work on improving our docs.

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





Thank you for your valuable feedback

Is this page helping you?

Yes
No

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

Contact our Support team for immediate help while we work on improving our docs.

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





Thank you for your valuable feedback!

Talk to an Expert
Download Copy Check Circle