The USB debugging mode on Xiaomi smartphones is a hidden feature for developers that allows access to advanced settings through the computer. Without it, you can not unlock the bootloader, flash custom software or use tools like ADB and Fastboot. However, the manufacturer hides this option in the depths of the menu, and on new versions of MIUI 13/14 added additional restrictions.
In this article, you will find current ways to enable debugging for all Xiaomi, Redmi and POCO models (including Android 13/14) devices, as well as solving common errors such as missing a βDevelopers forβ item or blocking MIUI after connecting to a PC. We will understand why some firmware requires binding a Mi Account before unlocking, and how to circumvent restrictions without the risk of βbrickingβ the phone.
What is USB debugging and why you need it on Xiaomi
Regime. USB Debugging (debugging by USB) β It's a tool for the interaction of a smartphone with a computer at a low level:
- π§ Install custom firmware (LineageOS, Pixel Experience)
- π± Unlock the bootloader for modifications
- π₯οΈ Use it. ADB-task-mates
- π Recover data after failures TWRP
- π οΈ Testing apps in Android Studio
On Xiaomi, this mode is blocked by default due to the security policy of MIUI. The manufacturer struggles with unauthorized modifications, so new devices (such as Xiaomi 13 Ultra or Redmi Note 12 Pro+) may need to link the Mi Account before unlocking the bootloader. Without debugging via USB, you will not even be able to start the unlock process through the official Mi Unlock Tool tool.
β οΈ Attention: Activation of debugging by USB Resets Knox protection (on Qualcomm chip devices) and may result in loss of warranty (POCO F5, Xiaomi 12T) When the bootloader is unlocked, Widevine stops working. L1 β video from Netflix and Disney+ It will be shown in low resolution.
Preparation of the smartphone: what to do before turning on debugging
Before activating the debugging mode, follow the mandatory steps:
Make sure battery power > 50% | Update MIUI to the latest version | Connect phone to stable Wi-Fi | Backup data in Mi Cloud | Disable "Find device" in your Mi--> account settings
Pay special attention to the version MIUI. On firmware older MIUI 12.5 the debugging algorithm may differ. e.g. on Xiaomi Mi 9s MIUI 11 is enough 5 taps for the build number, and on the Redmi Note 11 with MIUI 13 will require confirmation through SMS.
Also check if your Mi Account is allowed to unlock the bootloader.
- Go to en.miui.com/unlock
- Sign in with the same account as on your phone.
- Check the status in the Unlock Now section β if the button is active, you can continue
Xiaomi 13/14 series|Redmi Note 11/12|POCO F4/F5|Xiaomi 12T/12S|Another model-->
Step-by-step: how to enable debugging by USB on MIUI 14
The algorithm is relevant for all Xiaomi, Redmi and POCO Android 10-14 devices with MIUI 12.5-14 firmware. If you have an older version, skip the confirmation steps via SMS.
Step 1. Unlock "Developer Options"
- Open the Settings. β The phone.
- Find the line MIUI version and tap it 7 times in a row
- Enter your password/pattern lock if you request it.
- The message will be: βYou are a developer!β
Step 2: Activate debugging over USB
- Return to the main Settings menu
- Go to Additional Settings β Developer settings
- Find the USB Debugging option and move the slider to the right
- Confirm the action by pressing OK in the pop-up window
Step 3: Confirm your PC permission (on first connection)
- Connect your phone to your computer through the original USB-cable
- On the screen of the smartphone will appear the request: βAllow debugging over USB?β
- Check the box to always allow from this computer
- Press Allow.
What if a request for debugging permission does not appear?
Solving problems: USB debugging doesnβt turn on or work
Even with the right actions, debugging may not work. Consider the typical mistakes and their solutions:
| Problem. | Reason. | Decision |
|---|---|---|
| No item "Developer's Options" | 7 not performed by the MIUI version | Repeat taps in Settings β About the phone β MIUI version |
| Gray slider "Debugging by USB" | Active OEM (Factory Unlocking) | Enable OEM Unlocking in Developer Settings |
| The computer does not see the device in Adb devices | There are no drivers or incorrect USB mode | Install [drivers] ADB](https://developer.android.com/studio/run/win-usb) and select mode MTP |
| The error is "Unauthorized" in ADB. | Unconfirmed. RSA-key | Disconnect/connect the cable and allow debugging again |
| Debugging is disabled after rebooting | MIUI's defense worked. | Add Mi Account to Settings β Accounts and Re-enable |
If after all the manipulations, adb devices still show unauthorized, reset the ADB permissions:
adb kill-server
adb start-server
adb devicesβ οΈ Attention: On devices with MIUI 14 and Android 13+ (For example, Xiaomi 13 Pro or Redmi K60) After the debugging is enabled, additional confirmation may be required through SMS. This is a security measure, the code will come to the number associated with the Mi Account. Without confirmation, debugging will be blocked every 24 hours.
Debugging by USB to unlock the bootloader: nuances
If your goal is to unlock the bootloader for custom firmware installation, consider:
- π On New Devices (Xiaomi 13, POCO F5) Requires to link the Mi Account to the phone at least 7 days before unlocking.
- β³ The unlock process through the Mi Unlock Tool takes up to 720 hours (30 days) of waiting on new models.
- π± After unlocking, all data will be reset (full wipe), including photos and apps.
- π§ Some features (Google Pay, Widevine) L1) They may stop working.
To check the bootloader lock status, run the command:
adb reboot bootloader
fastboot oem device-infoIf you see Device unlocked: false in the answer, the bootloader is locked.
π‘
Before unlocking the bootloader, disable all Google and Mi accounts in your phone settings, which will speed up the process of linking the new device after the reset.
How to disable debugging by USB on Xiaomi
If the debugging mode is no longer needed, it can be deactivated:
- Go to Settings β Additional settings β Developer settings
- Turn off the debugging slider via USB
- Confirm the action in the dialog window
To reset your ADB permissions completely (for example, before selling your phone) do:
adb revoke-usb-debugging-authorizationSome firmware (MIUI 13+) may have an "unsecured connection" notification after debugging is disabled to remove it:
- Reboot the phone.
- Clear the App's cache Settings in Settings β Apps β Application Management
π‘
Disabling debugging over USB does not reset the bootloaderβs unlock status. If you have already unlocked the bootloader, it will remain unlocked even after deactivating the developer mode.
Security: Risks of enabling debugging over USB
Activating debugging over USB opens up potential vulnerabilities:
- π΅οΈββοΈ Remote access: An attacker with physical access to a phone can steal data through a phone ADB.
- π² Malware installation: Through debugging, you can install applications without your knowledge.
- π Bypassing locking: On some firmwares, you can reset the pattern lock through ADB.
To minimize the risks:
- π Enable debugging only when connected to a trusted PC.
- π‘οΈ Turn off the mode after completion of work.
- π Use a complex password to unlock the screen (not a pattern lock).
On devices with MIUI 14, the USB Lock feature is added, which automatically disables debugging when you connect to unknown computers, to activate it:
- Go to Settings β Passwords and Security β USB Lock
- Enable the option to Block USB Connections
- Add your current PC to your trusted device list