BrowserStack’s documented Detox cloud workflow runs Android tests on real devices: build the Android app and Detox test client, upload both, configure Detox with their returned bs:// identifiers and BrowserStack credentials, then run the cloud configuration. BrowserStack labels the integration beta. The instructions below cover Android; BrowserStack’s broader iOS and Android device catalogue does not establish Detox cloud support for iOS.
Before you start
- A React Native Android project with Detox configured and an Android app that builds locally.
- A BrowserStack Username and Access Key. Store them as environment variables or CI secrets; do not commit credentials.
- For Detox 20.51.3 and later, BrowserStack’s guide specifies
@browserstack/detoxversion20.51.3-cloud.0. Package compatibility and beta support can change, so check BrowserStack’s current Detox instructions before upgrading or adopting this in CI.
For Detox versions earlier than 20.51.3, the guide documents a legacy package path. BrowserStack says it continues to support older Detox versions with their previous configurations, while new patches and updates go to its newer package.
// package.json dependency for Detox 20.51.3 and later
"detox": "npm:@browserstack/detox@20.51.3-cloud.0"
// Documented legacy dependency for earlier Detox versions
"detox": "npm:@avinashbharti97/detox@^20.26.3"
After changing the dependency, BrowserStack advises removing node_modules and package-lock.json, then reinstalling dependencies. If the app build fails after integrating the BrowserStack package, the guide suggests trying the original Detox version; that is a troubleshooting suggestion, not a guaranteed fix.
Build the Android app and Detox client
Bundle the React Native app
For the Metro bundler, BrowserStack’s example places the production JavaScript bundle in Android assets. Create the directory and run the bundle command from the project root:
#1 Best Overall
- Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
- Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
- Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
- Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
- 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
mkdir -p android/app/src/main/assets
npx react-native bundle --platform android --dev false --entry-file index.js
--bundle-output android/app/src/main/assets/index.android.bundle
--assets-dest android/app/src/main/res
If your project uses a different entry file or bundler, adapt the command to produce the Android app’s bundle and assets in the locations expected by that build.
Allow Detox loopback traffic
Detox uses unencrypted requests to the loopback interface. Configure the Android app’s network_security_config.xml to permit cleartext traffic for 127.0.0.1, and ensure that configuration is attached to the app manifest. This is an app-level loopback permission; it is separate from BrowserStack Local, which provides a tunnel from cloud devices to private development services.
Assemble both APKs
From the Android project directory, build the app under test and the Android test-suite APK (the Detox app client):
Rank #2
- 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
- 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
- Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
- 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
- What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
./gradlew assembleDebug
./gradlew assembleAndroidTest
In the standard React Native debug build layout used in the upload examples, the resulting files are android/app/build/outputs/apk/debug/app-debug.apk and android/app/build/outputs/apk/androidTest/debug/app-debug-androidTest.apk. If your Gradle variants or output paths differ, upload the corresponding app APK and test-client APK from your build.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Upload the app and test client separately
BrowserStack requires both artifacts. The app upload endpoint accepts APK or AAB files, supplied as a multipart file or a publicly accessible url. The app-client endpoint likewise accepts APK or AAB uploads. These cURL examples use multipart files and Basic authentication:
Upload the app under test
curl -u "$BROWSERSTACK_USERNAME:$BROWSERSTACK_ACCESS_KEY"
-X POST "https://api-cloud.browserstack.com/app-automate/detox/v2/android/app"
-F "file=@android/app/build/outputs/apk/debug/app-debug.apk"
The response includes an app_url with a bs:// identifier. The API endpoint is documented at BrowserStack’s Android Detox app upload endpoint.
Rank #3
- Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
- Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
- Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
- Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
- What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
Upload the generated app client
curl -u "$BROWSERSTACK_USERNAME:$BROWSERSTACK_ACCESS_KEY"
-X POST "https://api-cloud.browserstack.com/app-automate/detox/v2/android/app-client"
-F "file=@android/app/build/outputs/apk/androidTest/debug/app-debug-androidTest.apk"
Use the returned app_client_url identifier alongside the app identifier. The endpoint is documented at BrowserStack’s Android Detox app-client upload endpoint. Both upload APIs support custom_id if you want a stable reference across build uploads. Uploaded builds expire after 30 days, so refresh the identifiers when needed rather than treating them as permanent.
Configure Detox to run on BrowserStack
In the BrowserStack cloud configuration, define an Android app using the two current upload identifiers, then define a cloud device and a Detox configuration that includes BrowserStack authentication and session metadata. The documented Detox server is wss://detox.browserstack.com/init. Configuration schema and package compatibility may change, so use the current configuration shape from BrowserStack’s Detox guide rather than copying an old config into a newer package version.
Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallProvide credentials through environment variables or your CI secret store, not a checked-in configuration file. Once the cloud configuration is named android.cloud.debug, run:
Rank #4
- Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
- Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
- Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
- Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
- Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
detox test -c android.cloud.debug --loglevel trace
The trace log is useful while resolving setup failures. BrowserStack’s dashboard shows test results and debugging details. For logs through the API, BrowserStack documents a Detox session route; you need the session ID printed by the CLI or available in the dashboard.
Testing an app that depends on private services
Uploading the Android binary does not give a BrowserStack device access to a service bound to your laptop or a private development network. Establish BrowserStack Local’s secure tunnel before the test when the app needs those services. BrowserStack describes its Local connection as using secure WebSockets (WSS). Treat the tunnel as an additional network prerequisite, not as a substitute for the app’s Android loopback permission.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.What this workflow supports—and what remains beta
BrowserStack’s Detox materials describe testing native and hybrid apps on real Android phones and tablets. App Automate’s broader catalogue includes iOS and Android devices, but that does not demonstrate Detox cloud execution on iOS; the getting-started examples containing iOS simulator configurations do not establish that either. Verify directly with BrowserStack before planning an iOS cloud Detox run.
Free tools Windows power users keep installed
One-click scans. No signup required.
Best Value
- 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
- Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
- Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
- HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
- What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
BrowserStack’s getting-started documentation says, “This feature is currently in the beta phase, and we will make updates based on the feedback we receive.” Confirm current package instructions and availability before relying on the integration for a release-critical pipeline. General App Automate capabilities such as parallel execution or network-condition controls should not be assumed to apply to this Detox integration unless BrowserStack confirms that they do.
Troubleshooting
- Dependency replacement breaks the Android build: remove
node_modulesandpackage-lock.json, reinstall, and retry. If the build still fails, the guide suggests trying the original Detox version; check compatibility with BrowserStack before deciding which package to keep. - The cloud run cannot find the app or test client: verify that each configuration field uses the matching identifier from its own upload response:
app_urlfor the app andapp_client_urlfor the app client. - An identifier worked previously but no longer resolves: the uploaded app and client builds expire after 30 days. Upload fresh artifacts and update both configured identifiers.
- The app opens but cannot reach a private API or development service: start BrowserStack Local and configure the app to use the reachable service address. Uploading an APK alone does not create private-network access.
- Detox cannot make its loopback request: check that Android’s network security configuration permits cleartext traffic to
127.0.0.1and that the manifest points to that configuration. - The test command runs locally instead of using the cloud: check that
-cnames the cloud configuration and that this configuration contains both current artifact IDs, BrowserStack credentials, and the documented cloud server. - You are trying to run the same setup on iOS: the documented cloud Detox flow here is Android-focused. Do not infer iOS Detox support from App Automate’s device catalogue; confirm the supported path with BrowserStack.
Or skip the browser setup
ScreenshotNeo is a website screenshot API, not a Detox runner or a replacement for testing a React Native app on Android devices. If your separate need is to capture a web page as an image, one GET request returns a screenshot:
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
See the ScreenshotNeo API documentation. It removes cookie banners, newsletter popups and chat widgets before capture; bot checks, blank pages and failed loads are not billed. An MCP server lets AI agents use screenshot tools, and 1,000 screenshots per month are free with no card; paid plans start at $5 for 3,000. Sign up for 1,000 free screenshots a month with no card.
Frequently Asked Questions
Can I use BrowserStack Detox cloud testing for iOS?
The documented BrowserStack Detox cloud workflow covered here is Android-focused; confirm iOS support with BrowserStack before planning for it.
Do I upload one APK or two?
Upload both the Android app under test and the generated Detox app-client test APK.
How long do uploaded Detox builds remain available?
The BrowserStack upload API documentation states that uploaded app and client builds expire after 30 days.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

