Troubleshoot ADB device not showing or being recognized
Congratulations! If you too are facing issues in connecting your device to ADB, you are in the perfect place. This blog will troubleshoot the issue of ADB devices not showing or being found in the list.
First things first, what is ADB?
Android Debug Bridge (ADB) is a versatile command-line tool that lets you communicate with a device. The ADB command facilitates a variety of device actions, such as installing and debugging apps, and it provides access to a Unix shell that you can use to run a variety of commands on a device. However, you first need to install the ADB package on your computer if it is not already installed. The easiest way to do this is to:
- Install the Android SDK tools if not already installed. You can install it on your Windows by clicking here, on macOS from here and on Linux from here. The rest of the process remains the same for all three.
- Extract the zip folder into an easy-access location such as C://PlatformTools.
- Navigate to the extracted directory and open a command prompt in the same directory as your PlatformTools.
- Next, enable USB debugging on your Android Device from Developer Options. To unlock Developer Options, go to Settings->About Phone and tap seven times on the Build Number.
- Connect your Android device to your PC using a USB cable and open the command prompt in the same directory as your PlatformTools.
- Enter the command adb devices to get the list of your devices.
- You should see your Android device in the output of the above command. This ensures that your device is connected.
- However, if running the command adb devices does not output your device name, stick with this blog and we will troubleshoot this issue.
How to fix the issue
Below, we will be discussing some of the probable solutions that most likely solve the issue of Android devices not being detected in ADB. The solutions will be in order from the easiest fix going down to a bit complex fixes so make sure you try them all from the start. So let’s get started without further ado.
Making sure Android device is not connected as Media Device_
The easiest fix and the most common reason for Android devices not showing up in ADB is because it is connected as a Media Device. To disconnect it as a media device, go to your Android device’s Settings -> Storage -> Menu(three dots in the corner) and tap on USB Computer Connection and uncheck both MTP and PTP if not already unchecked.
Now, try to connect your device to ADB and run the adb devices command. This time, you should now see your device name in the output meaning that it is now detectable.
Restarting the server
If the above fix of unchecking MTP and PTP didn’t work for you, this might. Most of the time, killing and restarting the ADB server gets the job done. To do this:
- Enable developer options for your Android device. However, since you are trying to connect it to your ADB, it must already be enabled as you need USB debugging to be switched on for it.
Next, enable the Stay awake toggle button present in the Developer Options.
- Make sure USB debugging is enabled and your device is connected to your computer via USB connection.
- Open the command terminal on your computer and navigate to your platform-tools directory using the cd command followed by the location of your platform-tools.
- Run the command adb kill-server.
- Next, start the server again by running the command adb start-server.
- Finally, run the command adb devices and your device should now be visible.
In conclusion, these were a few of the ways to fix the issue of ADB device not showing up. Hope you try them out and hope that they solve your issue.