ADB Over Wifi – Android Debug Bridge on TCP

How can I connect Android device with ADB over Wifi? is the most asked question by new developers. Connecting Android device with ADB over TCP is a straight forward process.In this post, I m going to demonstrate each step involved in connecting ADB via TCP. Android Debug Bridge is the command line tool that allows communication between a development system and Android enable device. ADB is an important part of Android application development. ADB can only connect with an android device over TCP/IP if both are on the same local network. They are connected from a TCP/IP port.

How to connect Android device with ADB over Wifi or TCP

Step 1
Create a new project in Android Studio with default settings and name it ADBTutorial.

Step 2
Connect your Android device via USB with your development machine running Android Studio. Android Studio will detect your Android device as soon as it connects.

Step 3
Open the Terminal and below are the commands involved in the process. Each command has been explained in the following steps.

adb over wifi

Execute below command to navigate to the “platform-tools” directory.
$ cd library/android/sdk/platform-tools

Step 4
Execute below command to see the list of connected devices. We can see the connected device as shown in above image. It is connected via USB.
$  ./adb devices

Step 5
Type below command to restart the adb server in TCP mode
$  ./adb tcpip 5555

Step 5
Find out the ip address of android device. We can find the ip address as below
Settings -> About Phone/tablet -> Status -> IP address.

adb over wifi ip

Step 6
Execute below command to connect with a device over TCP as shown in above image.

$  ./adb connect 192.168.0.104

Now Android device is connected to ADB over TCP. We can remove the USB cable now.

Step 7
As we have removed the USB cable and our device is connected remotely. To verify that device is connected over TCP. Execute below command

$  ./adb devices

It is displaying the connected device IP address as shown in above image.

Finally, we have connected Android device with ADB via TCP. Pressing Run App button will launch the application in the remotely connected device.

I hope you will like this tutorial. Subscribe to our Newsletter to get new articles and tutorials in your inbox as soon as they published. You can connect with us on Facebook and also subscribe to our Youtube Channel

Check Also

asynctask kotlin example

Kotlin AsyncTask Tutorial with Example

Here is an example of implementing AsyncTask in Kotlin. I will create an Android application …