When Xiaomi is locked, it can be for a variety of reasons, from the banal loss of password to the desire to access hidden features of the system for installing custom firmware. Unlocking through the computer is the most reliable and often the only possible way to bring the device back to life. Unlike resetting through the menu, which may not be available, working with the PC allows you to interfere with low-level download processes.
However, it is worth noting that unlocking the bootloader and resetting the forgotten password are technically different procedures, although they use similar tools. If you forget the pattern lock, you will most likely need to reset data via Recovery or Fastboot. If your goal is to modify the system, then you need a formal process of unbundling your account through the company's servers.
Before taking action, you need to assess the risks. Any interference with the shell carries the potential threat of data loss or, in rare cases, turning the device into a brick. Windows must be functional and the device must be in good condition. USB-cable - original or qualitative analogue, capable of transmitting data, not only current.
β οΈ Note: Unlocking the bootloader in an official way through Mi Unlock leads to the complete removal of all data from the device.
The process requires attention to detail, as an error in the stage of setting up an account or selecting a firmware version can lead to locking the device using IMEI or the occurrence of authorization errors.
Preparation of the Mi Account and setting up the smartphone
The foundation of the whole procedure is to link the device to your Mi Account. Without this step, Xiaomi servers will not give permission to unlock, and the Mi Unlock utility will give an error. You need to log into your account in the phone's settings menu and make sure that it is active and confirmed via SMS or email.
Then activate the hidden menu for developers. Go to Settings β About Phone and quickly click 7-10 times on the MIUI Version (or HyperOS Version). After the notification βYou became a developerβ return to the main settings menu, select Additional β For developers.
In the list that opens, find and activate the following switches:
- π± Factory unlocking (OEM unlocking β allows unlocking the bootloader.
- π» Debugging by USB β Allows the computer to interact with the Android system.
- π Mi Unlock status β a point for linking an account to a device.
Click on the last paragraph and follow the instructions on the screen. The system will warn about the risks and require a mobile Internet connection (Wi-Fi at this point often does not work or causes errors). Once the status is successfully associated, the account will be indicated that the account is associated with this device.
βοΈ Checking before unlocking
It is important to know that once an account is linked to a device, it is often necessary to wait a certain time (7 to 168 hours) before the server allows unlocking, a security measure to prevent device theft.
What to do if the timer is not going?
Necessary software and installation of drivers on PC
The main tool is the Mi Unlock Tool, which can only be downloaded from the official website miui.com/unlock. Using third-party versions can lead to data leakage or virus infection.
Windows 10 and 11 often automatically find the underlying drivers, but Fastboot and ADB mode may require specific files. It is recommended to install the universal ADB Driver Installer package or drivers that come with the Mi PC Suite.
After installing the software, connect the phone to your computer by holding the volume button. The screen should show a picture of a hare repairing an android and the inscription FASTBOOT. In the Windows Device Manager, the Android Bootloader Interface should appear in the section "USB Controllers" or "Android Device".
If you see a βUnknown Deviceβ with a yellow exclamation point instead, the drivers are not installed correctly, in which case you will need to manually specify the path to the drivers through the Device Manager by selecting the model of your processor (Qualcomm or MediaTek).
π‘
Use it. USB-port 2.0 (black) on the back of the system unit if port 3.0 (blue) causes connection errors. USB 2.0.
Unlocking process with Mi Unlock Tool
Once the drivers are installed and the phone is ready, you can start the process by running the Mi Unlock Tool on behalf of the administrator and log in to the same Mi Account that is attached to the smartphone.
If done correctly, the Unlock button will become active. Click on it and confirm the action in the window that appears. The unlock process will begin, which will take from a few seconds to a few minutes, during which time the phone can restart, and the progress bar on the PC screen will fill up.
The table below shows the main statuses you can see in the process:
| Status on the programme | Meaning | User actions |
|---|---|---|
| Connecting... | Searching device | Check the cable and Fastboot mode |
| Unlocking... 0-99% | The unlocking process | Do not turn off the cable, wait for the end |
| Unlocked successfully | Successful unlocking | You can close the program and restart the phone. |
| Error 10006 | Server/network error | Check the Internet, change the DNS or time |
Once completed, the phone will automatically restart.The first boot may take longer than usual (5-10 minutes) and a warning may appear on the screen that the bootloader is unlocked, which will disappear after a few seconds.
π‘
Successful completion of the process is confirmed by the inscription "Unlocked successfully" and automatic restart of the device with the cleaning of all user data.
Alternative method: resetting password through ADB
If your goal is not to unlock the bootloader for firmware, namely, to remove the forgotten pattern lock or PIN-code, and at the same time on the phone was pre-enabled debugging USB, You can try it from the command line, and it doesn't work on all Android versions because of the security enhancement, but it's worth a try.
You'll need a folder with Platform-tools (ADB) installed. Open the command prompt (CMD) in this folder. Connect your phone in normal mode (not Fastboot).
adb devicesIf the device is identified, try to delete the files that store the access keys. Enter the following command:
adb shell rm /data/system/gesture.keyOr, for older versions:
adb shell rm /data/system/password.keyOnce you have completed the command, restart your phone. The lock screen should disappear or allow any password to be entered. However, on modern versions of HyperOS and new MIUIs, this method is often blocked by security.
Common mistakes and ways to solve them
The unlocking process rarely goes perfectly smoothly for all users, and the most common problem is an authorization or timer error, and if a program says "Unable to unlock (10008)," it often means that the required time has not passed since the account was linked.
Another common problem is a 99% freeze or a βCouldnβt verify deviceβ error, which may indicate an unstable Internet connection or a lockdown of Xiaomi servers by your provider, and in such cases, using mobile Internet (distribution from your phone) instead of Wi-Fi helps, as it is a problem that is not easily accessible to you. IP-Mobile operatorsβ addresses are less likely to be blocked.
Also worth mentioning is the driver problem: If the computer sees the phone as a charger, but not as a data transfer device, try:
- π Replace USB-cable to the original (PowerBank cables are often only charged).
- π» Use the other USB-port, preferably directly on the motherboard.
- π‘οΈ Temporarily disable Windows antivirus and firewall that can block the connection.
β οΈ Warning: If, after unlocking, the phone requires you to enter a password from your Mi Account when you turn it on, and you don't remember it, it will be extremely difficult to restore access.
Security and Consequences of Unblocking
The unlocked bootloader changes the security status of the device, and some banking applications and services (such as Google Pay or Mir Pay) may stop working or require additional manipulation to hide root rights, because the unlocked Bootloader is considered a vulnerability.
In addition, when unlocking, the Widevine L1 section is erased, which is why streaming services (Netflix, Disney+) can reduce the playback quality to HD (480p) instead of Full HD or 4K. Returning the L1 level after official unlocking is almost impossible without soldering the chips.
On the other hand, you get full control of the device, you can install customized recaps (TWRPs), make full backups of the system, remove system debris and change the visual shell beyond recognition, a choice between maximum security out of the box and complete freedom of customization.