Getting Started with DeviceLab
Get up and running with DeviceLab in minutes. This guide walks you through connecting your first devices and running your first automated mobile test on your private device farm. No code changes required - your existing tests work unchanged.
Prerequisites
- macOS, Linux, or Windows machine
- Android SDK (for Android devices) or Xcode (for iOS devices)
- Physical devices connected via USB, or emulators/simulators
Quick Start
Step 1: Connect Your Devices
Run the Device Node to connect your devices to DeviceLab:
bash
curl -fsSL https://app.devicelab.dev/device-node/YOUR_ORG_KEY | sh
Replace YOUR_ORG_KEY with your organization ID from the DeviceLab dashboard.
You’ll see output like:
____ _ _ _ _
| _ \ _____ _(_) ___ ___ | \ | | ___ __| | ___
| | | |/ _ \ \ / / |/ __/ _ \ | \| |/ _ \ / _` |/ _ \
| |_| | __/\ V /| | (_| __/ | |\ | (_) | (_| | __/
|____/ \___| \_/ |_|\___\___| |_| \_|\___/ \__,_|\___|
Device Node starting...
Connecting to server...
Connected! Devices available: 3
- Pixel 8 (Android 14)
- iPhone 15 Pro (iOS 17.1)
- iPad Air (iOS 17.0)
Step 2: Run Your First Test
Maestro
bash
curl -fsSL https://app.devicelab.dev/test-node/YOUR_ORG_KEY | sh -s -- \
--framework maestro \
--platform android \
--app ./app.apk \
--tests ./maestro-tests
Appium
Appium requires two terminals:
Terminal 1 - Start Appium server:
bash
curl -fsSL https://app.devicelab.dev/test-node/YOUR_ORG_KEY | sh -s -- \
--framework appium \
--app ./app.apk
Wait for: Appium server ready on http://localhost:4723
Terminal 2 - Run your tests:
bash
# Java/Maven
mvn clean test
# Python
pytest
Note: Connect to
http://localhost:4723/wd/hubin your test code. Don’t set theappcapability - DeviceLab handles it automatically.
Step 3: View Results
Test results are available in:
- Terminal: Real-time output as tests run
- Dashboard: app.devicelab.dev for detailed reports, screenshots, and videos
Architecture Overview
DeviceLab has two main components:
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ Device Node │────▶│ DeviceLab │◀────│ Test Node │
│ │ │ Server │ │ │
│ • Physical │ │ │ │ • Maestro │
│ • Emulators │ │ • Coordination │ │ • Appium │
│ • Simulators │ │ • Streaming │ │ • Espresso │
│ │ │ • Results │ │ • XCUITest │
└─────────────────┘ └─────────────────┘ └─────────────────┘
- Device Node: Connects your devices to DeviceLab
- Test Node: Executes tests on allocated devices
- Server: Coordinates devices, runs tests, stores results
What’s Next?
| Guide | Description |
|---|---|
| Connecting Devices | Set up Device Node with simulators, emulators, and physical devices |
| Running Tests | Learn Test Node options and device selection |
| Appium Testing | Run Appium tests on DeviceLab |
| Maestro Testing | Run Maestro tests on DeviceLab |