Skip to content

Command line

Terminal window
android-emu-web [--port <port>] [--no-open]

The gateway runs in the foreground until you press Ctrl+C. Stopping it does not stop running emulators.

Option Default Effect
--port <port> 7300 The port the gateway listens on, on 127.0.0.1 only.
Option Default Effect
--no-open off Do not open the browser on start. The gateway still prints the address.

--no-open and the address with the token are part of the launch flow described in First run.

Variable Effect
ANDROID_HOME The Android SDK directory. Without it, the gateway uses ~/Library/Android/sdk.
ANDROID_AVD_HOME The directory that holds AVDs. Without it, the gateway uses ~/.android/avd.
DEBUG=1 Print one line per second for each connection: frames received, sent and dropped, average frame size, and the delay from the emulator to the gateway.

ANDROID_AVD_HOME is read when the gateway lists devices.

ANDROID_HOME is read by the first-run check.

On start, the gateway prints the address of the page. If no emulator is running, it prints the reason and keeps running.

The printed address has the form https://droid.devpier.dev/app/#port=<port>&token=<token>, and the gateway opens it with the macOS open command unless you pass --no-open.

On first run, missing Android SDK parts are listed with a fix each, and the gateway asks [y/N] before installing anything. See First run.

What Where
Gateway listen address 127.0.0.1:<port>
Running emulator discovery ~/Library/Caches/TemporaryItems/avd/running/pid_<pid>.ini
What Where
Emulator gRPC ports it assigns The first free even port from 8554
What Where
Installed executable ~/.local/bin/android-emu-web