How to Setup Frida Server on Your Rooted Android Phone
Introduction
Frida is a dynamic code instrumentation toolkit used heavily by security researchers and reverse engineers to analyze applications. To hook into Android applications and bypass mechanisms like SSL Pinning, you must first have the Frida Server running continuously on your rooted Android device.
In this guide, we will walk through the exact steps required to download, install, and execute the Frida Server on a rooted Android phone.
Prerequisites
Before starting, ensure you have the following ready:
- A Rooted Android Device: You need an actual rooted device or a rooted emulator (like Genymotion or LDPlayer) running Magisk.
- Platform Tools (ADB): Installed on your computer so you can send commands to the device.
- USB Debugging Enabled: Enabled inside the Android Developer Options.
Step 1: Identify Your Device Architecture
Frida provides different server binaries depending on your Android device’s CPU architecture. We need to find out what processor your device has.
Connect your connected device and run the following command in your computer’s terminal:
1
adb shell getprop ro.product.cpu.abi
Typical outputs include:
arm64-v8a(Most common for modern Android phones)armeabi-v7a(Older 32-bit phones)x86_64orx86(Common for Android Emulators)
Step 2: Download the Correct Frida Server
- Head over to the official Frida GitHub Releases page.
- Look for the asset named
frida-server-<version>-android-<architecture>.xz. - For example, if your device architecture from Step 1 was
arm64-v8aand the latest version is17.9.1: downloadfrida-server-17.9.1-android-arm64.xz. - Extract the
.xzarchive (use 7-Zip on Windows orunxzon Linux/Mac) to get the rawfrida-serverbinary perfectly.
Step 3: Push the Frida Server to Your Device
Now we need to transfer this binary to a temporary folder on your Android device (we typically use /data/local/tmp/ because it is writable and can execute binaries).
Run the following command where your extracted file is located:
1
adb push frida-server /data/local/tmp/
Step 4: Grant Permissions and Run
The binary is on your Android phone, but it doesn’t have execution permissions yet, and it needs to be run with root access.
(Note: If you are using an emulator, you may need to run adb root on your computer before proceeding!)
- enter the Android shell:
1
adb shell
- Switch to the
rootuser context. You might get a Magisk prompt on your phone’s screen that you need to accept:1
su
- Navigate to the temporary directory:
1
cd /data/local/tmp/ - Give the binary executable permissions:
1
chmod 755 frida-server - Run the server in the background:
1
./frida-server &
Note: If you encounter an error (like address already in use), a Frida server might already be running. You can kill it using killall frida-server.
Step 5: Verify the Connection
Open a new terminal tab on your computer (keep the old one running the server) and verify that Frida can communicate with your device by running:
1
frida-ps -U
(The -U flag stands for USB).
If everything is configured perfectly, this command will spit out a long list of all the processes and background services currently running on your Android phone!
Conclusion
Your rooted device is now fully prepped with a running Frida Server! You can now write or use existing JavaScript hooking scripts to manipulate running applications, bypass network layers, read memory, and reverse engineer security implementations.