Debugging mode via USB on Xiaomi: how to turn on in 5 minutes (all models 2026)

Debugging mode by USB on Xiaomi smartphones is a hidden feature, without which it is impossible to perform most technical operations: from firmware via fastboot to data recovery via ADB. Despite the fact that the manufacturer hides this option in the menu for developers, its activation takes no more than 5 minutes - if you know the exact sequence of actions.

The problem is that MIUI interfaces (especially versions 14 and 15) change regularly, and instructions from older sources often lead to a dead end. For example, Android 14 has a different path to developer settings than Android 12, and some POCO models require additional bootloader unlocking. This article presents current ways to enable USB debugging for all 2026 Xiaomi, Redmi and POCO devices, including bypassing typical bugs.

Why do you need to debug USB on Xiaomi?

USB Debugging allows you to access low-level smartphone functions through your computer.

  • πŸ”§ Install custom firmware (LineageOS, Pixel Experience) via fastboot or TWRP.
  • πŸ“± Recovering deleted data with the help of ADB pull or specialized utilities like Dr.Fone.
  • πŸ”“ Unlock the bootloader for rooting or system modification.
  • πŸ–₯️ Manage your smartphone from a PC via scrcpy (screen viewing, keyboard commands input).
  • πŸ› οΈ Test apps in Android Studio or debug them via logcat.

However, there are risks: if you use ADB incorrectly, you can erase data, disrupt the system, or even turn your smartphone into a brick. For example, a command to fastboot erase system without a backup will lead to the loss of firmware.

⚠️ Attention: Including debugging by USB shut off MIUI, Don't connect your smartphone to unverified PCs, which can lead to malware installation.

πŸ“Š Why you need to debug for USB?
Installation of custom firmware
Data recovery
Unlocking the loader
Control with PC (scrcpy)
Application testing
Other

Preparation of the smartphone: unlocking the menu β€œFor developers”

Before you start debugging, you need to activate the hidden menu "Developers" on Xiaomi, this process is standard, but there are nuances for different versions of MIUI:

  1. Open the Settings. β†’ The phone.
  2. Find the line MIUI version and tap it 7 times in a row (on some models – by Assembly Number).
  3. After the notification β€œYou became a developer!” appears, return to the main settings menu.

On MIUI 15 (based on Android 14), the path may be different: Settings β†’ Additional β†’ About Phone β†’ MIUI Version. If the Developer Menu doesn’t appear, check if it’s hidden in Settings β†’ Additional β†’ Special Features.

What if you don’t say β€œYou’re a developer”?
If after 7 taps nothing happens: 1. Check if time synchronization is enabled in Settings β†’ Additional β†’ Date and time (automatic mode). 2. Reboot your smartphone and try again. 3. Some firmware (for example, global for POCO F5) requires you to tap on the Assembly Number, not the MIUI Version. 4. If you use MIUI EU or custom firmware, the path can be changed - look for the Developer options section manually through the search in the settings.

Step-by-step: how to enable debugging by USB

After unlocking the developer menu, follow the following steps:

  1. Go to Settings β†’ More β†’ For Developers (or Settings β†’ System β†’ For Developers on Android 13+).
  2. Activate the debugging switch on USB (USB debugging).
  3. In the confirmation window that appears, click OK or Allow.
  4. Connect your smartphone to your PC through the original USB-cable (cheap cables may not support data transmission).
  5. On the screen of the smartphone will appear the request "Allow debugging by USB from this computer?". Check the box Always allow from this computer and click Allow.

If you don’t have ADB drivers installed on your PC, your smartphone won’t be recognized. Download them from the official Android Studio website or use Xiaomi ADB/Fastboot Tools utility.

The original one is connected. USB-cable|Included menu "For developers"|The "Debugging by" switch is activated USB"|Drivers are installed on the PC ADB|Smartphone recognized in Device Manager-->

Typical errors and their solutions

Even with the right actions, USB debugging may not work, and here are the most common problems and ways to fix them:

Mistake.Reason.Decision
The smartphone is not defined in adb devicesThere are no drivers or incorrect connection modeInstall Google USB Driver and select File Transfer (MTP) mode when connecting
No request for debugging permission appearsReset developer settings or MIUI Optimization enabledDisable MIUI Optimization in the Developer Menu and Reboot the Smartphone
Unauthorized in the output of adb devicesNot confirmed confidence in the PC on the smartphoneDisconnect/connect the cable again and confirm the request on the screen
Debugging is disabled after rebootingActive OEM Unlocking function without unlocking the bootloaderUnlock the bootloader via Mi Unlock Tool or disable OEM Unlocking

⚠️ Attention: On Xiaomi models 13/14 series POCO F5 Pro with Android 14 If debugging is off on its own, check if the smartphone is tied to a Xiaomi account with two-factor authentication.

πŸ’‘

If your smartphone isn’t recognized in fastboot, try using a USB 2.0 port on your PC – some motherboards have issues with USB 3.0 when working with ADB.

Features for different Xiaomi models

The process of enabling debugging over USB is universal, but some devices have nuances:

  • πŸ“± Xiaomi Redmi Note 12/13: Developer menu can be hidden in Settings β†’ Memory. β†’... (three-point) β†’ Special facilities.
  • πŸ“± POCO F4/F5: Required to turn off MIUI Optimization for stable operation ADB.
  • πŸ“± Xiaomi 12T/13T: On global firmware, a debugging permission request appears only after connecting to the Mi Flash Tool.
  • πŸ“± Black Shark 5/6: We need to turn it on. OEM Unlocking before activating debugging, otherwise fastboot will not work.

On smartphones with a MediaTek processor (for example, Redmi 10C or POCO M5), you need to use the SP Flash Tool utility instead of the standard adb to work with fastboot.

Security: How to protect data when debugging is enabled

Debugging over USB opens up potential vulnerabilities to minimize the risks:

  1. Turn on debugging only when necessary and turn it off after use.
  2. Use trusted PCs – Connecting to public computers (such as in an internet cafe) can lead to data theft.
  3. Set a screen lock password – without it, anyone with physical access to a smartphone will be able to get root rights through ADB.
  4. Check the list of authorized devices in the developer menu (Revoke USB debugging permissions).

Nana MIUI 15: The function USB Debugging Security, which blocks access to data without fingerprint confirmation or PIN-Activate it in the developer menu.

πŸ’‘

Never connect a USB-enabled smartphone to charging stations at airports, hotels or other public places – this is one of the most common ways to hack devices.

Checking the work of debugging by USB

To make sure that the debugging works correctly:

  1. Connect your smartphone to your PC and open the command line (Windows) or terminal (macOS/Linux).
  2. Enter the command: adb devices In response, something like: List of devices attached 1234abcd5678 device
  3. If the device is displayed as unauthorized, confirm trust on the smartphone screen.
  4. To verify full access, run: adb shell getprop ro.product.model The command must return the model of your device (e.g. 2304FPCD8G for POCO F5).

If no permissions are displayed instead of the model, then the debugging is not enabled correctly or the drivers are installed incorrectly. Reinstall the ADB Interface Driver through Device Manager.

FAQ: Frequent questions about debugging on USB on Xiaomi

Can I enable debugging over USB without a developer menu?
No, it's impossible. The developer menu is a prerequisite for debugging activation. If it doesn't appear after 7 taps on the MIUI version, try: Update your smartphone to the latest version of MIUI. Reset to factory settings (as a last resort). Use ADB via Mi Flash Tool (for firmware only).
Why did the USB debugging stop working after the MIUI update?
Updates often reset developer settings. To restore access: Re-enable the developer menu (7 taps on the MIUI version). Activate debugging over USB and confirm trust in the PC. If adb: device unauthorized occurs, delete the adbkey.pub file in the %USERPROFILE%\.android folder on the PC and reconnect the smartphone.
How to enable debugging by USB on a locked Xiaomi smartphone?
If the screen is locked (forgot the password) and USB debugging has been enabled earlier, you can try unlocking the device via ADB: adb shell rm /data/system/gesture.key adb shell rm /data/system/password.key After rebooting, the lock will reset. Attention: this method only works on Android 9 and below. New versions require unlocking the bootloader and installing TWRP.
Do I need to unlock the bootloader for debugging over USB?
No, bootloader unlocking is only needed for: Install custom firmware (TWRP, LineageOS). Get root rights through Magisk. Restore data via fastboot. For standard USB debugging (for example, scrcpy or Android Studio), unlocking is not required.
How to disable USB debugging on Xiaomi?
To deactivate mode: Go to Settings β†’ Additional β†’ For developers. Turn off the USB Debugging switch. To completely reset authorized devices, click Revoke permissions to debug USB. If the developer menu is hidden, it can be turned off by resetting the smartphone settings to factory settings (Settings β†’ Phone β†’ Reset).