A locked Xiaomi smartphone is a problem that users face after buying a device from hand, resetting settings or trying to install custom firmware. Mi Account locking or a locked bootloader does not allow you to perform flashing using standard methods, and official unlocking methods often require waiting or confirmation from the previous owner. In this article, we will discuss legal and semi-legal methods of bypassing locks, choosing the right firmware and installing it Step-by-step through Fastboot or EDL.
It is important to understand that the procedure involves the risk of losing warranty, turning the device into a brick or activating hardware protection (for example, Anti-Rollback on new models).We do not call for violation of Xiaomi license agreements, but describe the technical possibilities for owners who legally purchased the device. If the phone is stolen, unlocking through informal methods can lead to blocking IMEI.
The article is relevant for Redmi, POCO and Mi models based on Qualcomm and MediaTek processors released before 2026. New devices (for example, Xiaomi 14 or Redmi Note 13 Pro+) may require additional steps due to tightening of protection.
Why is Xiaomi blocking the flashing?
Xiaomi has implemented several levels of protection against unauthorized access:
- π Mi Account - linking the device to the owner's account. After resetting the settings (Hard Reset) requires entering the username / password of the previous user.
- π Locked bootloader β new devices have the bootloader closed by default. Unlock requires a wait time (from 72 hours to 30 days) through the official Mi Unlock Tool.
- β οΈ Anti-Rollback: Reversed from older firmware versions, and if you try to install an earlier version, the device can lock permanently.
- π± IMEI-locking β on some models (for example, Redmi Note 10 Pro) when the firmware is incorrectly reset IMEI, What makes your phone unsuitable for calls.
The main purpose of these restrictions is to combat theft and fraud, but legitimate users often suffer from excessive protection, especially when buying used devices, for example, if the previous owner forgot to unplug the Mi Account or sold a phone with a locked bootloader.
β οΈ Note: On devices with MediaTek processor (e.g. Redmi) 9A, POCO C31) unlock EDL This may cause hardware damage to the memory module. Before the procedure, check the model of the chipset in the application. CPU-Z.
Preparation for unlocking: what to do before the firmware
Before you start flashing, follow the mandatory steps:
- Check the device model. You can find out the exact modification in the settings (Settings β About Phone β Model) or through the command: adb shell getprop ro.product.model For example, Redmi Note 8 Pro has the code name begonia, and POCO X3 NFC is surya.
- Download the necessary tools: π₯οΈ Official Mi Unlock Tool (to unlock the bootloader). π± Unofficial Xiaomi Flash Tool (for firmware through the EDL). π§ ADB Fastboot (from the Platform Tools package). π Firmware for your model (about where to get it - in the next section).
Prepare the computer.
Mi Unlock Tool
Xiaomi
here
Fastboot
If the device is locked on Mi Account, try contacting the previous owner to unblock it, otherwise you will have to use workarounds (about them below).
Where to download firmware for locked Xiaomi
Choosing the right firmware is a critical step, and installing the wrong version can lead to a hard-brick.
| Type of firmware | Source | For what occasions? | Risks. |
|---|---|---|---|
| Official (Fastboot) | Xiaomi website | Unlocking the bootloader, recovery after failure | Requires unlocked bootloader, may not bypass Mi Account |
| Castomium (TWRP) | XDA Developers | Installation of unofficial firmware (for example, LineageOS) | Possible loss of features (NFC, camera), risk of blocking |
| EDL-firmware | Xiaomi Firmware Updater | Mi Account recovery after hard-brick | Requires an authorized Qualcomm account or a patched EDL |
| Anti-Rollback fix | Telegram channels | Anti-Rollback protection bypasses on new models | High risk of becoming a brick |
For most users, the best option is the official Fastboot firmware from Xiaomi, which is suitable for unlocking the bootloader and restoring functionality. EDL-patch-patch.
β οΈ Note: Firmware from unknown sources (such as torrent trackers) may contain spyware or viruses. Always check hash files (MD5) post-download.
Example of the official firmware name for Redmi Note 9 Pro (codename joyeuse):
joyeuse_global_images_V12.5.1.0.RJWMIXM_20211012.0000.00_11.0_global_1d1a1a1a1a.tgzWhere:
- joyeuse is the code name of the device.
- Global is the firmware region.
- V12.5.1.0.RJWMIXM - version of MIUI
- 11.0 is the Android version.
Method 1: Unlock the bootloader via Mi Unlock Tool (official method)
If the bootloader is locked but the Mi Account is not tied (or you know the previous owner's details), use the official Mi Unlock Tool.The process takes 3 to 30 days due to Xiaomi's policy.
βοΈ Preparation for unlocking the loader
Steps:
- Activate Developer Mode: Go to Settings β About Phone and click on MIUI Version 7 times.
- Enable USB Debugging and OEM Unlocking in Settings β More β For Developers.
- Connect your phone to your PC, launch the Mi Unlock Tool, and log in to the same Mi Account as your phone.
- Follow the instructions of the program. At the unlock stage, the device will reboot to Fastboot (black screen with a rabbit).
- When you first unlock, Xiaomi requires a wait (usually 168 hours).
After successful unlocking, you can flash the device through Fastboot:
fastboot flash boot boot.img
fastboot flash system system.img
fastboot rebootβ οΈ Note: On devices with MediaTek (e.g. Redmi) 9T) Unlocking the bootloader via the Mi Unlock Tool may not work. SP Flash Tool or EDL.
π‘
If the Mi Unlock Tool gives you a "Couldn't unlock" error, try connecting the phone to another one. USB-port (preferably 2.0) or use another PC. Sometimes it helps to disable the driver signature in Windows.
Method 2: Firmware through EDL (bypass Mi Account and blocked bootloader)
EDL (Emergency Download Mode) allows you to flash a device even with a locked bootloader and a Mi Account tied. This method works on most Xiaomi devices with Qualcomm processors, but requires a special cable or short circuit contacts on the board.
What you need:
- π EDL-cable (or ability to solder to close test point).
- π» Mi Flash Tool or QFil (for Qualcomm).
- π Firmware in.mbn or.elf format (you can download it on Xiaomi Firmware Updater).
- π Qualcomm Authorized Account (or Patched Account) EDL community).
Instructions:
- Turn off the phone to enter the room. EDL use one of the methods: π§ Special cable: connect USB-cockpit+ and D- (sold on AliExpress). π₯ Test point: disassemble the device and close the contacts on the board (for each model they are different, look for schemes on the board). XDA or 4PDA).
Qualcomm HS-USB QDLoader 9008
here
Mi Flash Tool
Refresh
COM-port
Flash
If the firmware is successful, the device will reboot in standard mode without being tied to the Mi Account. However, on new models (such as the Xiaomi 12T), Anti-Rollback can work, and the phone will lock permanently.
What if the phone doesnβt turn on after EDL?
Method 3: Bypassing Mi Account without firmware (for older models)
If the device is locked on Mi Account, but the bootloader is unlocked, you can try to bypass the check without completely flashing it.This method works on Xiaomi until 2019 release (for example, Redmi Note 5, Mi A1).
Method 1: Through TWRP
- Install custom TWRP recavators via Fastboot: fastboot flash recovery twrp.img fastboot boot twrp.img
- In TWRP, go to Advanced β File Manager.
- Delete files: /data/system/locksettings.db /data/system/locksettings.db-wal /data/system/locksettings.db-shm /data/system/gesture.key /data/system/gatekeeper.password.key
- Reboot the device. The Mi Account lock should disappear.
XDA Developers has themes that are bypassed, but they often stop working after MIUI updates.