FIX: Unauthorized Device with ADB Commands

So you’re running an ADB command, most likely ‘adb devices,’ and in addition to getting the device-specific code, you also get an unapproved message. This tutorial will explain why this mistake occurs and, more importantly, how to resolve it. Follow along for step-by-step instructions on how to resolve the illegal device error while using ADB commands.

There is a slew of reasons why you might need to use the ADB commands. The ability to boot your device into Fastboot/Bootloader Mode is one of the most critical. Aside from that, you can use it to sideload apps or boot your smartphone into standard recovery or a custom recovery like TWRP.

Most of these can also be accomplished using your device’s physical key combinations, although remembering the key combinations is not straightforward. This is due to the fact that there is no standard combination; each OEM has their own set of keys for entering Fastboot or Recovery Mode. Things are different with ADB commands, and for the better.

The nice thing about these commands is that they’re universal, meaning they’ll work on any Android device. It is also independent of Android versions, making it many people’s favorite way of communication. However, some users may receive an unapproved device error while running the commands. We’ll explain why you’re getting the illegal device error when running ADB commands in this guide, as well as how to repair it. Follow along with me.

Reason for Unauthorized Device Error

While there are a few possible causes for this problem, one of the most common is that you haven’t authorized your PC to detect your device in ADB Mode. As you can see, you’ve enabled USB Debugging on your device, which is why you’re getting the alphanumeric code. Because you haven’t granted your authorization to approve this connection, you’ll get an unauthorized notification.


As a result, the linked device isn’t recognized by your Mac or Windows PC. It has nothing to do with the USB drivers or missing ADB or Fastboot files. It’s only that you don’t have the necessary authorization. With that out of the way, let’s look at how to repair the illegal device issue while running ADB commands.

How to Fix Unauthorized Device with ADB Commands

To begin, we always recommend that our readers stay away from various third-party ADB and Fastboot programs. When working with these binary files, you should always use the Google-provided package. And that’s exactly what we’ll be talking about in this tutorial. So, let’s get started with the instructions, starting with the correct ADB and Fastboot files from the Silicon Valley behemoths.

STEP 1: Download and Install Android SDK Platform Tools

Google’s Android SDK Platform Tools binary packages can be downloaded and installed. Extract the file to any location on your computer once it has been downloaded. You now have all of the necessary ADB and Fastboot files. You can also learn more about the Command Line Tools by consulting Google’s  Official Documentation.

STEP 2: Enable USB Debugging

It’s now time to enable USB Debugging on your phone or tablet. To do so, go to Settings > About Phone > Tap 7 times on Build Number (Xiaomi users should tap 7 times on MIUI version) > You will be notified that you are now a developer in a toast message.


Return to  Settings > System > Advanced (or Additional Settings) > You should now see the Developer Options. Tap that, then scroll down to USB Debugging and turn on the toggle next to it. Allow USB Debugging will now appear in a popup window; touch OK. Also, have a look at our tutorial on Enable USB Debugging on a Broken Android Device’s Screen? Here’s a Workaround.


Android USB Debugging.

STEP 3: Authorize USB Debugging [3 Methods]

1. Now comes the most crucial part of this guide: resolving the illegal device problem while using ADB commands. Please carefully follow the steps below:

2. Connect your gadget to your computer via a USB cord. Check to see if Debugging is turned on.

3. [FIX 1] Allow USB Debugging using your PC’s RSA Fingerprint key will appear as soon as you connect to the PC. Allow is selected, and if this is your own computer, you can also select Allow from this computer.


4. But what if your device doesn’t have the prompt? Well, that’s not a problem; you can still go forward and the prompt will reappear.

5. Go to the platform-tools folder (where the Android SDK was installed/extracted). Type CMD into the address bar of that folder and press Enter. The Command Prompt will open as a result of this.


6. In the CMD window, type the following command:

adb devices


7. [FIX 2] You should now have the alphanumeric ID and the device keyword if you previously allowed the RSA Fingerprint key. If you didn’t get the prompt before, you’ll get it now if you run the ‘adb devices’ command. So, go to your smartphone and hit the Allow button in the popup window that displays. That is all there is to it.

8. [FIX 3] Still not having any luck? It turns out, however, that there is a third option. This time, go to Settings > System > Advanced > Developer Options and select Debugging from the drop-down menu. Revoke USB Debugging Authorization can be found there. Then, in the dialog box that displays, tap OK.


9. Connect your device to your PC via USB connection once more, this time with USB Debugging enabled. Navigate to the platform-tools folder, then put CMD into the address bar and press Enter. Now, in the CMD window that you just opened, type the following command:

adb devices

10. Your device will now display a prompt; press Allow, and your device will be identified. Simply re-run the adb devices command, and you should no longer see the unauthorized keyword next to the device ID.


We’ve come to the end of our guide on how to use ADB commands to fix the Unauthorized Device problem. We’ve offered three alternative techniques for doing so, each of which should guarantee your success. If you have any further questions, please contact us. Please share your thoughts in the comments box below. We will respond as quickly as possible with a solution.

Leave a Reply

Your email address will not be published. Required fields are marked *