Debugging mode via USB on Xiaomi: how to turn on in 5 minutes (relevant for MIUI 14)

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.

  1. Go to en.miui.com/unlock
  2. Sign in with the same account as on your phone.
  3. 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"

  1. Open the Settings. β†’ The phone.
  2. Find the line MIUI version and tap it 7 times in a row
  3. Enter your password/pattern lock if you request it.
  4. The message will be: β€œYou are a developer!”

Step 2: Activate debugging over USB

  1. Return to the main Settings menu
  2. Go to Additional Settings β†’ Developer settings
  3. Find the USB Debugging option and move the slider to the right
  4. Confirm the action by pressing OK in the pop-up window

Step 3: Confirm your PC permission (on first connection)

  1. Connect your phone to your computer through the original USB-cable
  2. On the screen of the smartphone will appear the request: β€œAllow debugging over USB?”
  3. Check the box to always allow from this computer
  4. Press Allow.
What if a request for debugging permission does not appear?
If when connecting to the PC does not pop up a window with a request for debugging, check: 1. Cable and port USB: Use the original cable and port USB 2.0 (blue connector on PC β€” USB 3.0 (Yellow/Red may not work. 2. Drivers. ADB: set up [Mi PC Suite](https://pcsuite.mi.com/) or drivers manually through [device manager](https://developer.android.com/studio/run/win-usb). 3. File Transfer Mode: On your phone, select File Transfer Mode (MTP), Not just charging. 4. Reboot: Turn off the cable, restart the phone and PC, then reconnect.

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 versionRepeat 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 devicesThere are no drivers or incorrect USB modeInstall [drivers] ADB](https://developer.android.com/studio/run/win-usb) and select mode MTP
The error is "Unauthorized" in ADB.Unconfirmed. RSA-keyDisconnect/connect the cable and allow debugging again
Debugging is disabled after rebootingMIUI'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-info

If 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:

  1. Go to Settings β†’ Additional settings β†’ Developer settings
  2. Turn off the debugging slider via USB
  3. Confirm the action in the dialog window

To reset your ADB permissions completely (for example, before selling your phone) do:

adb revoke-usb-debugging-authorization

Some firmware (MIUI 13+) may have an "unsecured connection" notification after debugging is disabled to remove it:

  1. Reboot the phone.
  2. 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:

  1. Go to Settings β†’ Passwords and Security β†’ USB Lock
  2. Enable the option to Block USB Connections
  3. Add your current PC to your trusted device list

FAQ: Frequent questions about debugging on USB on Xiaomi

Can I enable debugging over USB without a Mi Account?
On devices up to MIUI 12 (like the Redmi Note 8 Pro), debugging is enabled without an account being tied. On newer models (Xiaomi 13, POCO X5), Mi Account is required to unlock the bootloader, but not for debugging itself.
Why is the phone not identified in ADB after debugging?
Check: Drivers installed (try the official Google drivers) and File Transfer Mode selected (MTP) When you connect. Is the service active? ADB (run adb start-server in the command line. If the problem persists, try another one. USB-cable (original) or port on PC.
How to enable debugging on USB on blocked Xiaomi (forgot the password)?
On a locked phone, you can't debug if it hasn't been activated before. The only options are: Restore access via Mi Account (if an account is tied). Reset your phone via Fastboot (loss of all data): fastboot flashing unlock fastboot flashing unlock_critical
Does USB debugging work on Xiaomi with a damaged screen?
If the screen is not responsive to touch, but the phone is turned on, you can control it via ADB from the PC. Connect the device and do: adb shell input tap x y # emulation tap adb shell input text "hello" # input text adb shell input input input input inputevent 3 # Home button Tap coordinates (x y) can be found through applications like Screen Coordinates (set it in advance).
Can I enable USB debugging on Xiaomi via computer (without phone access)?
No. Enabling debugging requires physical access to the phone to activate the option in the settings. The only workaround is if the device has already unlocked the bootloader and installed custom recovery (TWRP). In this case, you can: Boot to TWRP (hold Power + Vol Up when you turn on). Connect to the PC and use ADB in recovery mode.