Manage frida-server on an Android device/emulator via ADB.
Automatically downloads the frida-server build that matches the host's installed frida CLI version, pushes it to the device, and starts it. Root access is auto-detected: on rooted devices frida-server runs as root; on non-rooted devices it runs as the shell user and can only instrument debuggable apps.
./frida_android.sh <command>
| Command | Description |
|---|---|
start |
Ensure frida-server is installed at the matching version and launch it (aliases: on, up) |
stop |
Kill frida-server on the device (aliases: off, down) |
restart |
Stop, then start |
status |
Show device/host versions, running pid, port, connectivity (alias: st) |
install |
Download + push frida-server, do not start |
uninstall |
Stop and remove the on-device binary |
| Variable | Default | Description |
|---|---|---|
FRIDA_VERSION |
host frida --version, then latest |
Force a specific frida-server version |
FRIDA_PORT |
27042 |
Listen port for frida-server |
FRIDA_REMOTE |
/data/local/tmp/frida-server |
On-device install path |
FRIDA_CACHE_DIR |
$HOME/.cache/frida-android-server |
Host cache directory for downloaded binaries |
adbin PATH with a connected device/emulatorcurlandxzon the hostpython3on the host (only needed when falling back to GitHub for the latest version)frida/frida-toolson the host (recommended) so versions match automatically andstatuscan verify connectivity- Root (
su) on the device is recommended (Magisk, userdebug, etc.) but not required — the script auto-detects root and falls back to non-root mode
When running without root, frida-server executes as the shell user. This means:
- Only debuggable apps (
android:debuggable="true"or debug builds) can be instrumented - System services and production apps cannot be attached to
- Some status checks (e.g.
netstat) may return less information
FRIDA_VERSIONenv var if set- Output of
frida --version(host CLI) - Latest GitHub release tag from
https://api.github.com/repos/frida/frida/releases/latest
Downloaded binaries are cached, so subsequent runs are offline as long as the version doesn't change.
# First run: downloads matching frida-server, pushes, and starts it
./frida_android.sh start
# Confirm everything is up
./frida_android.sh status
# Talk to it from the host
frida-ps -U
# Pin a specific version
FRIDA_VERSION=16.7.11 ./frida_android.sh restart
# Use a non-default port
FRIDA_PORT=27045 ./frida_android.sh start
# Tear down completely
./frida_android.sh uninstallln -s "$PWD/frida_android.sh" ~/bin/frida_android