A forgotten pattern or digital lock code on a Xiaomi smartphone instantly restricts access to all data, turning the functional device into a closed screen asking for authorization. The user loses the ability to make calls, use applications and files, however, the built-in tools of Android and the MIUI shell allow you to reset the protection through the Mi account, the Find My Device function or Recovery mode if certain pre-configuration conditions were met.

There are many myths about how easy it is to bypass the protection without losing data, but the reality is that modern encryption methods make a full reset the most secure way. In this article we will look at all current options: from using a cloud service Mi Cloud to entering recovery mode Recovery Mode. It is important to understand that some methods require preliminary synchronization, while others are guaranteed to delete all information from the drive.

Before taking active steps, you need to determine your device model and firmware version. Older versions MIUI had vulnerabilities that made it possible to reset the lock screen through the recovery menu without formatting, but in current builds this path is closed for security reasons. If the phone was purchased recently, most likely you will have to deal with the procedure of completely deleting data.

Using the Mi Cloud service for remote unlocking

The most civilized and safest way to regain access to the device is to use the official cloud service from the manufacturer. If you've signed in to your smartphone and have Find My Device turned on, you can erase your lock data remotely. This method requires another device with Internet access. Mi Account and Find My Device is enabled, you can erase your lock data remotely. This method requires another device with internet access.

First, go to the official website i.mi.com from a computer or another phone. You will need to enter the login and password for your account Xiaomi. The system may request identity verification through a code sent to the linked phone number or backup email. After successful authorization, you will see a map with the location of your devices.

Select a locked smartphone from the list of available gadgets. In the device management menu, find the "Wipe Data" or "Wipe Data" button. Pressing this button will send a command to the phone that will erase all user data, including the set password, pattern or PIN. The phone will reboot and go into factory settings.

⚠️ Attention: This method will only work if the locked phone is connected to a Wi-Fi network or mobile data. If the device is in airplane mode or turned off, the command will be executed immediately after it appears on the network.

It is worth noting that after resetting, on the activation screen you may be required to enter the password for the same Mi Accountthat was used previously. This is an anti-theft protection (FRP Lock) that cannot be bypassed by a simple reset. Make sure you remember your account details before starting the procedure.

💡

Remote reset via Mi Cloud is the only way to maintain the device's warranty, as it does not require opening the case or using third-party software.

📊 How did you usually protect your phone before it was locked?
Pattern key
Digital PIN code
Fingerprint
Face recognition
Did not protect at all

Password reset via Recovery mode (Hard Reset)

If you have Internet access the locked device does not have or you do not remember the data from the Mi account, the only way out is a hard reset. This method is performed through a special service menu Recoverybuilt into the phone's memory. It does not require a computer or additional apps.

The procedure begins by completely turning off the smartphone. If the device does not respond to pressing the power button due to locking, press the Volume Up and Power keys at the same time and hold them for about 10-15 seconds until the screen goes dark and the Milogo appears. As soon as the logo appears, release the power button, but continue to hold Volume Up.

You will be taken to the main menu Recovery. Navigation here is carried out using the volume buttons (up/down), and the selection of an item is confirmed with the power button. You need to find the section Wipe Data. In new versions of MIUI, this item may be called “Erase data” or “Factory Reset.”

After selecting the item, the system will ask you to confirm the action, since this is an irreversible operation. Select Wipe All Data and confirm your choice. The process of formatting the data partition will take from a few seconds to a couple of minutes, depending on the amount of occupied memory and the speed of the drive.

☑️ Algorithm for entering Recovery

Done: 0 / 4

After cleaning is completed, the message “Data wiped successfully” will appear on the screen. Select item Back to Main Menu, and then Reboot -> Reboot to System. The phone will reboot and you will see the initial setup screen, as when purchasing a new device.

Action Result Saving data
Entering the wrong password 5 times Temporarily blocking 30 sec Yes
Reset via Mi Cloud Full device wipe No
Hard Reset (Recovery) Return to factory settings No
Unlocking via ADB Deleting the key file (rarely) Partially
What to do if the Recovery menu is in Chinese?

If you are in the Chinese Recovery menu, be guided by the icons or the location of the buttons. Usually the "Wipe Data" button is second from the top. To confirm the action, you need to select the bottom button in the dialog box that appears. You can also temporarily change the language in the main menu, if such an option is available (button with a globe or the letters En/Cn).

Unlocking using a Google account (outdated method)

On devices with Android versions lower than 5.0, it was possible to reset the pattern via a Google account. After several unsuccessful attempts to enter the password, the “Forgot your pattern key?” button appeared on the screen. By clicking on it, you could enter the login and password for the Gmail account associated with the device.

In modern realities, this method practically does not work on smartphones Xiaomireleased after 2016. Google's security policies have become stricter, and the ability to remotely reset the screen lock via the account's web interface has been removed. Now the Google account serves more as a factor for verifying ownership of the device after a reset (FRP) than as an unlocking tool.

However, on some custom firmware or very old models of the series Redmi first generations, this method may work. If after 5 unsuccessful attempts you see the corresponding button, try entering the data. Otherwise, do not waste time and move on to hardware methods.

⚠️ Attention: Do not try to endlessly guess the password. On modern devices, a timer is triggered to increase the blocking time exponentially. After a certain number of errors, the phone may be blocked for 12, 24 hours or require you to enter a password for your Mi account, which you may not have set specifically for blocking.

It is important to distinguish between screen locking and Google account locking. If you have forgotten your Gmail password, you can recover it on any other device via the website accounts.google.com. However, this will not unlock the phone itself if it has a pattern that is different from the account password.

💡

If you have a dual-SIM phone and one of the SIM cards is active, try calling the blocked number from another phone. On some older versions of MIUI, during an incoming call, you can minimize the call screen and access the desktop or settings.

Using USB debugging and the ADB utility

This method is intended for advanced users who, before blocking, had USB debugging enabled in the "For Developers" menu. Without this preset option, the method will not work. It allows you to send a command to delete a file that stores information about the pattern key via a computer.

You will need to install ADB drivers on your computer and connect your smartphone with a cable. Open a command prompt or terminal in the platform-tools folder. Enter the command to check the connection:

adb devices

If the list displays a device with status device, then the connection is established. If the status unauthorized, you will not be able to unlock the phone, since a debugging confirmation should appear on the screen, which you cannot press.

If the connection is successful, enter the command to delete the key file:

adb shell rm /data/system/gesture.key

For a digital password or PIN code, the command may differ depending on the Android version:

adb shell rm /data/system/password.key

After executing the command, reboot the device. In an ideal scenario, the phone will ask you to enter any key, and after entering it, the desktop will open. However, on versions of Android 6.0 and higher, as well as in MIUI 10-14, this file is often duplicated or encrypted, which makes the method ineffective.

💡

The ADB method works on less than 5% of modern devices due to changes in the Android security architecture, but remains the only chance to save data without a full reset.

Third-party apps for unlocking: myths and reality

On the Internet you can find dozens of apps with names like "Xiaomi Password Remover", "Android Unlocker", etc. Most of them are either paid dummies or contain malware. The principle of their operation usually comes down to automating entering Recovery mode and executing the Wipe Data command, which you can do yourself for free.

Some utilities, such as Tenorshare 4uKey or Dr.Fone, actually have databases of vulnerabilities for specific older models. They may try to exploit security holes in the bootloader. However, for current models Xiaomi Mi 11, 12, 13, 14 and series Redmi Note of recent years, these apps are useless.

Using such software carries risks: you can transfer personal data (if the phone suddenly becomes partially unlocked) to third parties or infect your computer with a virus. In addition, most "free" versions allow you to scan your phone, but require payment for the unlocking process itself, which ultimately leads to data deletion anyway.

⚠️ Warning: Beware of sites offering "unlock by IMEI" for money. In 99% of cases it is a scam. IMEI is used to identify the device on the network, but does not store information about your pattern or password.

The only exception is service utilities used in authorized centers that interact with the manufacturer’s servers to remove the lock if you have a purchase receipt. For the average user, this path is closed or economically unfeasible.

What to do after the reset: setup and protection

After a successful Hard Reset, the phone will return to its out-of-the-box state. You have to go through the initial setup: select a language, connect to Wi-Fi and log in to your accounts. Be prepared for the system to require you to enter the password for the last used Google account or Mi account.

This is an anti-theft mechanism (FRP - Factory Reset Protection). If you do not remember the password for these accounts, you will not be able to access your phone even after resetting. In this case, you will need to restore access to mail or contact Google/Xiaomi support with a receipt of purchase.

To avoid similar situations in the future, it is recommended to set up biometric unlocking. A fingerprint or face scanner is not only more convenient, but also allows you to reset your password through Settings if you forget your backup PIN. Also, be sure to write down your backup password somewhere safe, not on the phone itself.

💡

Set up the Smart Lock feature in your security settings. It allows you to keep your phone unlocked when it is at home (by geolocation) or connected to your smartwatch via Bluetooth.

Regularly backup important data to the cloud. Setting up synchronization of contacts, photos and notes will take a couple of minutes, but will save you from losing information in the following unforeseen circumstances. To do this, use both built-in MIUI tools and third-party services like Google Drive.

Frequently asked questions (FAQ)

Will resetting the password delete photos and contacts from the phone?

Yes, in the vast majority of cases, resetting the password on modern Xiaomi requires procedure Hard Reset or remote cleaning via Mi Cloud. This results in the complete deletion of all user data: photos, videos, contacts, messages and installed applications. The data will only be saved if it was previously synchronized with the cloud.

Is it possible to unlock Xiaomi without losing data?

You can unlock your phone without losing data only in two cases: if you had USB debugging enabled and you use ADB (rarely works on new models), or if you simply forgot the password, but the phone allows you to log in via fingerprint or Face ID, after which you can change the password in the settings. There are no official ways to reset a forgotten key while saving data.

What is FRP Lock and how to bypass it?

FRP Lock (Factory Reset Protection) is Google protection that requires entering the password from the account that was synchronized with the phone before the reset. You can bypass it using legal methods only by remembering your password. There are workarounds for vulnerabilities in specific versions of Android, but they are constantly closed by security updates and require complex manipulations with the PC.

Will the reset work if the phone is turned off?

No, the phone must be turned on to execute the password reset command. If you are using Mi Cloud, the device must be online. If you do a Hard Reset through the buttons, the phone will turn on in a special Recovery mode, but the data will be deleted only after confirmation and reboot to the main system.

How to find out if the Mi account is linked to the phone if it is locked?

It is impossible to find out for sure without access to the menu. However, if the phone was new when you purchased it and you set it up yourself, most likely your account is linked. If the phone is used and the previous owner did not log out of the account, after resetting you will receive an activation lock. In this case, only contacting the seller or providing a receipt to the service center will help.