Wireless debugging allows you to run Android debugging commands and deploy apps to your device over a Wi-Fi network without the need for a USB cable. This guide will walk you through the setup process.
- An Android device
- A computer with ADB installed
- Both your computer and Android device connected to the same Wi-Fi network
-
Connect Android Device via USB
Connect your Android device to your computer using a USB cable to initiate the wireless debugging setup.
-
Enable Developer Options
- On your Android device, open the "Settings" app.
- Scroll down and select "About Phone" or "About Device."
- Find and tap on "Build Number" multiple times (usually 7) until you see a message saying you are now a developer.
-
Enable USB Debugging
- Go back to the main "Settings" menu.
- Scroll down and select "Developer Options" or "System" -> "Developer options."
- Toggle on the "USB Debugging" option. You may need to confirm your device's PIN or pattern.
-
Connect to Wi-Fi
- Ensure that both your computer and Android device are connected to the same Wi-Fi network.
-
Open a Terminal or Command Prompt
On your computer, open a terminal or command prompt window. You will use this to issue ADB commands.
-
Check Connected Devices
- Run the following command to verify that your device is connected via USB:
Your connected device should be listed.adb devices
- Run the following command to verify that your device is connected via USB:
-
Enable Wireless Debugging
- Run the following command to restart ADB in TCP/IP mode:
adb tcpip 5555
- Run the following command to restart ADB in TCP/IP mode:
-
Find Android Device's IP Address
- You can find your Android device's IP address through various methods:
- Go to "Settings" -> "About Phone" -> "Status" -> "IP address."
- Check the Wi-Fi network settings on your device.
- Run
adb shell netcfg
and look for your device's IP address.
- You can find your Android device's IP address through various methods:
-
Disconnect USB Cable
Safely disconnect the USB cable from your Android device.
-
Connect to Android Device Over Wi-Fi
- Run the following command to connect to your Android device using its IP address:
Replaceadb connect [your_device_ip]:5555
[your_device_ip]
with the IP address from step 8.
- Run the following command to connect to your Android device using its IP address:
-
Verify Connection
- Run the command
adb devices
again. You should see your device listed with a status of "device."
- Run the command
-
Wireless Debugging Ready
Your Android device is now connected for wireless debugging. You can run ADB commands, deploy apps, and perform debugging tasks without a USB cable.
-
Optional: Reverting to USB Debugging
To switch back to USB debugging, simply connect your device via USB and run
adb usb
to reset the connection.
You have successfully set up wireless debugging for your Android device using ADB. This enables you to perform debugging tasks over a Wi-Fi network, providing flexibility and convenience for app development and testing.
Here are the commands you used in this guide:
# Check connected devices
adb devices
# Restart ADB in TCP/IP mode on port 5555
adb tcpip 5555
# Connect to your Android device over Wi-Fi using its IP address
adb connect [your_device_ip]:5555