Connecting Devices to DeviceLab
The Device Node connects your physical devices, emulators, and simulators to your private device lab. Once connected, devices become accessible for remote testing from anywhere - your laptop, CI/CD pipelines, or team members across the globe. This guide covers setup for Android, iOS, and virtual devices.
Quick Start
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh
Replace YOUR_ORG_KEY with your organization ID from the DeviceLab dashboard.
Command Line Options
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- [OPTIONS]
Options:
--name Custom name for this device node (default: hostname)
--enable-turn Enable TURN relay for restrictive networks
--apple-team-id Apple Team ID for iOS physical device testing
--simulators Comma-separated iOS simulators to add
--emulators Comma-separated Android emulators to add
Adding Simulators & Emulators
iOS Simulators
# Add specific simulators
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--simulators "iPhone 16,iPad Pro"
# With specific iOS versions
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--simulators "iPhone 16:18.0,iPad Pro:17.0"
Android Emulators
# Add specific emulators (AVD names)
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--emulators "Pixel_8,Pixel_Tablet"
Combined Setup
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--name "Houston-Office-MacMini-2" \
--simulators "iPhone 16:18.0,iPad Pro:17.0" \
--emulators "Pixel_8,Pixel_Tablet"
Physical Device Setup
Android Devices
- Enable Developer Options: Settings → About Phone → Tap “Build Number” 7 times
- Enable USB Debugging: Settings → Developer Options → USB Debugging
- Connect via USB: Connect device and authorize the computer
- Verify: Run
adb devicesto confirm device is detected
# Check connected devices
adb devices
# Expected output
List of devices attached
FA9AX2A4WE device
iOS Devices
- Connect via USB: Connect device to Mac
- Trust Computer: Tap “Trust” on the device prompt
- Verify: Device appears in Finder or
xcrun xctrace list devices
# Check connected devices
xcrun xctrace list devices
# Expected output
== Devices ==
John's iPhone (17.1) (00008030-000XXXXXXX)
iOS Physical Device Testing with Maestro
For Maestro tests on physical iOS devices, you need an Apple Team ID:
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--apple-team-id "ABCD1234EF"
Find your Team ID:
- Xcode → Preferences → Accounts → Select Apple ID → View Details → Copy Team ID
- Or:
security find-identity -v -p codesigning | grep "Apple Development"
Custom Node Name
# Set a descriptive name for this node
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--name "NYC-Office-MacMini-1"
Naming examples:
NYC-Office-MacMini-2- Location + machine typeSF-QA-Lab-Linux-3- Team + purposeBerlin-Remote-MacPro- Remote officeHome-Sarah-MacBook- Home setup
Network Configuration
Standard Setup
Most networks work automatically. Device Node uses WebRTC for device streaming with automatic NAT traversal.
Restrictive Networks
If you’re behind a strict firewall or symmetric NAT, enable TURN relay:
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- \
--name "Tokyo-Office-Mac" \
--enable-turn
Note: TURN relay routes traffic through third-party servers. Only enable if direct connection fails.
Network Detection
Device Node automatically detects your network type:
full_cone- Direct connection (no TURN needed)restricted- Address restricted NATport_restricted- Port restricted NATsymmetric- Requires TURN relay
Logs & Troubleshooting
Log Location
# Main log file
./log/devicenode.log
# Device-specific logs
./log/device/
Common Issues
Device not appearing:
# Android: Check ADB
adb devices
# iOS: Check device trust
xcrun xctrace list devices
Connection failed:
# Check network connectivity
ping app.devicelab.dev
# Try with TURN relay
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh -s -- --enable-turn
Simulator not starting:
# List available simulators
xcrun simctl list devices
# Boot manually if needed
xcrun simctl boot "iPhone 16"
Next Steps
- Running Tests - Execute tests on your devices
- Device Node CLI Reference - Full CLI documentation