Debugging by USB on Xiaomi Redmi 9: how to turn on the developer mode and activate the function

Xiaomi Redmi 9 is one of the most popular budget smartphones, but many users have difficulty trying to enable USB debugging, a feature that is necessary for working with ADB, firmware via Fastboot, obtaining root rights or transferring data using specialized utilities. Unlike other brands, on Xiaomi, the process is complicated by the hidden developer mode and features of the MIUI shell.

In this article, you will find a step-by-step illustration guide that is relevant to the Redmi 9 (M2003J15SC, M2004J19G and other modifications) on MIUI 12-14. We will discuss how to get around typical errors, why the function may not turn on, and what to do if the smartphone is not detected on the PC. You will also learn how to check that the debugging works correctly, and what hidden MIUI settings can block the connection.

Why do you need to debug USB on Xiaomi Redmi 9

Debugging by USB (USB Debugging is a tool for developers, but it's also useful for ordinary users:

  • πŸ”§ Install custom firmware through TWRP or Fastboot.
  • πŸ“± Get root rights with Magisk or SuperSU.
  • πŸ”„ Recover data after reset via Dr.Fone or Tenorshare.
  • πŸ–₯️ Control your smartphone from PC via scrcpy (real-time screen viewing).
  • πŸ› οΈ Correct system errors through ADB-team.

Redmi 9 also requires debugging to unlock the bootloader Unlock, without which it is impossible to install alternative software. Importantly, turning on this feature resets some security settings, so after activation, it is recommended to set a strong password on the lock screen.

πŸ“Š Why you need to debug for USB?
Installation of custom firmware
Getting root rights
Data recovery
Controlling with PC
Other

Preparation of the smartphone: unlocking the developer mode

On Xiaomi Redmi 9, the developer mode menu is hidden by default. To activate it, you need to perform a series of actions in the settings. Important: MIUI can request confirmation through Mi Account - make sure you remember the username and password from the Xiaomi account.

Instructions for MIUI 12-14:

  1. Open the Settings. β†’ The phone.
  2. Find the MIUI version and tap it 7 times in a row (you should be notified β€œYou became a developer!”).
  3. Return to the main Settings menu – there will be a new section Additional β†’ For developers.

If nothing happens after 7 clicks:

  • ❌ Check if the password is installed on the lock screen – without it, the developer mode is not activated.
  • ❌ Make sure you are using the version. MIUI, not on other lines (e.g., the device model).
  • ❌ Reboot your smartphone and try again.
What if the notification β€œYou became a developer” does not appear?
If the notification does not appear after 7 clicks, check: 1. System Updates: some versions of MIUI 13+ require a preliminary update to the latest firmware. 2. Regional settings: change region to "India" or "Global" in Settings β†’ Additional β†’ Region, then try again. 3. Reset: in extreme cases, perform a reset to factory settings (data will not be affected if you choose "Settings Reset" rather than "Clean All Data").

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

Once the developer mode is activated, you can start debugging. On Redmi 9, the process consists of 5 steps:

  1. Go to Settings β†’ Additional β†’ For developers.
  2. Find the USB Debugging option (usually in the Debugging block).
  3. Activate the slider and a risk warning will appear.
  4. Confirm the action by pressing OK.
  5. In the window that appears, select Allow Always from this computer (if connected to a PC) and click Allow.

If the USB Debugging option is inactive (grey), do:

Is the developer mode enabled (see previous section)

Is the smartphone connected to charging or PC (some firmware required)

Are Xiaomi drivers installed on your computer?

Is the power saving mode turned off for settings (Settings β†’ Battery β†’ Energy saving β†’ Energy saving settings β†’ Disable for β€œSettings”)

-->

Critical error: If the device stops being detected on the PC after debugging is enabled, check if the option to Revoke USB permissions in the developer menu is activated.

πŸ’‘

To speed up the search for the option "Debugging by USB", Use the search bar in the settings (the magnifying glass icon in the upper right corner "USB debug" or "debug".

Problems and Solutions: Why Debugging is Not Included

Even after doing the right thing, USB debugging may not work, and let’s look at the common mistakes and ways to fix them:

Problem.Reason.Decision
The USB Debugging Option is InactiveDeveloper mode not unlockedRepeat the taps using the MIUI version (see section 2)
The smartphone is not defined on the PCThere are no Xiaomi or ADB drivers.Install Mi PC Suite or drivers manually through Device Manager
The error is "Unknown command: adb"ADB not added to environment variablesDownload Platform Tools and specify the path to the folder in the system variables
Debugging is turned on, but after 5 minutes it is turned offPower saving mode for USB is activatedTurn off in Settings β†’ Battery β†’ Energy saving β†’ Energy saving settings β†’ USB

If a USB notification appears after connecting to your PC, change the connection mode:

  1. Swipe down the notification panel.
  2. Slip on the Charging notification via USB.
  3. Select File Transfer (MTP) or PTP.

πŸ’‘

On some MIUI 14+ firmware, USB debugging is blocked if the bootloader lock option is enabled in the security settings. Before activating debugging, check Settings β†’ Password and security β†’ Lock the bootloader and disable it.

Checking the work of debugging: ADB teams

To make sure that the USB debugging is working correctly, check through ADB:

  1. Connect Redmi 9 to your PC and allow debugging on your smartphone screen.
  2. Open the command line (Win + R β†’ cmd) and type:
adb devices

If you see the serial number of the device (e.g., 1234abcd device) in response, the debugging works.

  • 🚫 no devices found – check the cable connection or drivers.
  • 🚫 Unauthorized – the smartphone does not have a confirmed permission (check the notification).
  • 🚫 offline – restart the device and PC.

For additional diagnosis, use the command:

adb shell getprop ro.build.version.incremental

It must output the current firmware version (e.g., QKQ1.191222.002). If the command is not executed, the debugging is incorrectly configured.

Security: Risks and how to minimize them

Enabling debugging over USB opens up potential vulnerabilities, and an attacker with physical access to a smartphone can:

  • πŸ”“ Install malware through ADB.
  • πŸ“± Copy personal data (photos, messages, passwords).
  • πŸ› οΈ Change system settings without your knowledge.

To protect yourself:

⚠️ Warning: Never connect a smartphone with debugging enabled to public charging (at airports, cafes) or other people's computers. Use only trusted ones. USB-port.

  • πŸ”’ Turn off debugging after use (Settings) β†’ For developers β†’ Debugging by USB).
  • πŸ” Set a complex password/pattern lock on the lock screen.
  • πŸ›‘οΈ Enable data encryption in Settings β†’ Password and security β†’ Encryption.
  • πŸ”„ Regularly check the list of trusted computers in Settings β†’ For developers β†’ Withdraw permits USB.

MIUI 14 has added Debugging Protection, which requires you to enter a password every time you connect to your PC.

FAQ: Answers to Frequent Questions

Can I enable debugging over USB without developer mode?
No, on Xiaomi Redmi 9 (as with all MIUI devices), USB debugging is only available after the developer mode is activated. This is a security requirement embedded in the firmware. This restriction can only be circumvented through modified firmware (like LineageOS), but this requires unlocking the bootloader and losing warranty.
Why did the USB debugging disappear after the MIUI update?
Large updates (e.g. with the MIUI 12 on MIUI 14) resets some settings, including debugging permissions. To return the function: Reactivate Developer Mode (Taps according to version) MIUI). Put the debugging on. USB Connect to your PC and confirm the new resolution. If the option is gone, reset the settings through Settings. β†’ System system β†’ Resetting settings β†’ Reset all settings (data will not be deleted).
How to turn on debugging if the smartphone is not turned on (brick)?
If Redmi 9 doesn’t boot (hang on the logo or in Fastboot), USB debugging is impossible to enable – it only works on the working system. In this case: Connect your smartphone to your PC in Fastboot mode (press Power + Vol Down for 10 seconds). Use the Mi Flash Tool to flash the official software (requires an unlocked bootloader). If the bootloader is blocked, get permission to unlock through the Xiaomi site (it can take up to 720 hours of waiting). EDL-recovery (emergency firmware) is possible, but requires an authorized Xiaomi account.
Do I need to unlock the bootloader to enable debugging?
No, USB debugging and Bootloader Unlock are different functions. Debugging is enabled in the settings without loss of warranty, and unlocking the bootloader: Requires official permission from Xiaomi. Resets all data on the device. May lead to loss of warranty (depending on the region); Debugging is needed to unlock, but not vice versa. For example, you can use ADB to backup data before unlocking the bootloader.
What are the USB debugging alternatives for Redmi 9?
If debugging is on USB not enabled or blocked, consider alternative methods: Task Alternative Control with PC Mi PC Suite or AirDroid No access to system commands File Transfer MTP-Mode or cloud services Can not work with hidden folders Fastboot Mode (no debugging) Requires unlocked data bootloader Local backup in Settings β†’ System system β†’ Backup Some system files are not copied