The situation when the owner of a smartphone suddenly finds that he can not unlock the screen is one of the most stressful in the world of mobile technology.Graphic password is designed to protect personal data from prying eyes, but often becomes an insurmountable barrier for the owner after a system update or a long downtime gadget. If your Xiaomi has forgotten the graphic password, it is important not to panic and act in cold blood, as rash actions can lead to complete loss of information.
There are several proven methods of access recovery, the effectiveness of which depends on the version of MIUI, the device model and pre-enabled security settings. Modern Android shells have significantly increased protection, so old tricks with calling or sending SMS may not work on new firmware. In this article, we will discuss in detail current ways to solve the problem, ranging from the least radical to a complete reset system.
Before you start taking action, you need to understand what kind of lock is installed on your device. PIN-The type of protection and binding to the Mi Account will depend on the choice of the optimal unlock algorithm that will allow you to regain control of the gadget.
Using a Mi Account to Reset a Lock
The most civilized and secure way to restore access to a Xiaomi device is to use the built-in functionality of the Mi Account. If you have previously logged in and enabled the Find Device feature, unlocking is possible remotely through any browser, this method allows you to erase the forgotten key without losing personal files, photos and contacts.
First, you need to go to the official website cloud.mi.com or i.mi.com from a computer or other smartphone. Enter your credentials (login and password from Mi-account). If the system requires two-factor authorization, confirm the login through the code from SMS or backup email. After successfully logging into the cloud service, select your locked device from the list of available gadgets.
⚠️ Note: Remote unlocking via Mi-account works only if the locked phone is connected to the Internet (Wi-Fi or mobile network) and the option “Find the device” is activated in the settings».
In the device control menu, find the Unlock or Unlock button. Once you press it, the system will send a command to the smartphone and the lock screen will be reset. If there is no Internet on the phone, the command will be executed automatically once the gadget is in the network coverage area, which is the only way to keep the user's data intact.
Unlocking the Google Find My Device
An alternative that is relevant for devices with a pure Android operating system or global versions of firmware is Google Find My Device, which also requires an active Internet connection on the blocked gadget and an association with the Google account that was the main one on the device.
Go to android.com/find and log in to your Google profile. The system automatically locates all devices associated with that account. Select your Xiaomi from the list on the left. The action menu that appears will give you three options: Call, Lock, and Clear the Device.
It's important to note that on modern versions of Android 10, 11, 12 and above, Lock often doesn't allow you to set a new password, but you need to clean it right away. However, in some cases, especially on older models or custom firmware, you can set a temporary password that will replace the forgotten pattern lock. Enter a new code in the field, confirm the action, and try to unlock the phone with this code.
- 🔍 Make sure that geolocation and data transfer are enabled on the smartphone, otherwise the service will not see the device.
- 🔐 If Google’s two-factor protection is enabled, prepare your phone to receive a confirmation code.
- 📱 This method will not work if your Google account has been deleted from your device before being blocked.
If none of the cloud-based methods worked, it's likely that the phone doesn't have access to the network or the services that are needed have been disabled, and then you'll have to resort to more radical measures to reboot to recovery mode.
Resetting with Recovery Mode (Hard Reset)
The most reliable, but also the most destructive, method is a factory-wide reset, known as Hard Reset, which completely cleans the device’s internal memory by removing all apps, photos, contacts, and most importantly, a forgotten graphical password.
To enter Recovery Mode on Xiaomi and Redmi smartphones, you need to do a certain sequence of actions with the buttons. First turn off the device completely. Then press both the Volume Up and the Power button at the same time. Hold them until the Mi logo appears, then release the power button, but keep the volume.
☑️ Preparation for Hard Reset
When you see the Recovery menu (usually a black screen with text or an Android logo with an exclamation point), the volume buttons (up/down) are controlled, and the power button is selected. If the screen shows "dead Android", press both Power and Volume Up again to appear menu.
In the list, select Wipe Data, then Wipe All Data. The system will ask you to confirm the action by selecting Confirm. The cleaning process can take several minutes. Once completed, the phone will automatically restart, and you will see the screen of the initial setting, as when you first turn on the new device.
⚠️ Note: After the Factory Reset, Android security will require you to enter a password from a Google account or Mi Account that was synced to the phone before locking (FRP Lock).
Using ADB to delete key files
For advanced users who do not want to lose data and have enabled debugging USB (USB Debugging, there is a method of removing system files that store the pattern lock through the interface ADB (Android Debug Bridge: This method only works if you've previously given your computer permission to debug.
You'll need a computer with ADB drivers installed and a USB cable. Connect the locked smartphone to a PC. Open the command line or terminal on your computer in the ADB folder. Enter the adb device command to check the connection. If the debugging confirmation window appears on your phone screen and you hit OK, the device will appear in the list.
adb shell rm /data/system/gesture.key
adb shell rm /data/system/locksettings.db
adb shell rm /data/system/locksettings.db-wal
adb shell rm /data/system/locksettings.db-shmOnce these commands are executed, the file that stores the hash of the pattern lock will be deleted. Now you just need to restart the device or just extinguish and wake the screen. When you try to unlock, you can enter any graphic pattern or password - the system will let you inside, since there is no verification file.
What if the ADB can’t see the phone?
It’s worth noting that on newer versions of Android with disk encryption, this method may not be effective without first unlocking at least once after power is turned on. Encryption binds access keys to a user’s session, so deleting files may not work without knowing the password.
Comparison of Xiaomi Unlocking Methods
To make it easier for you to navigate the way you solve the problem, we have prepared a summary table that will help you quickly assess the risks of data loss and the conditions required for each method.
| Method | Data retention | We need the Internet. | Difficulty |
|---|---|---|---|
| Mi-account | Yes. | Yeah (on the phone) | Low. |
| Google Find My Device | No (most often) | Yeah (on the phone) | Low. |
| Recovery Mode (Hard Reset) | No. | No. | Medium |
| ADB Command | Yes. | No. | Tall. |
As you can see from the table, the only way to ensure that photos and correspondence are safe without prior preparation (like a backup) is to use cloud services, provided that the phone is actively synchronized. If the phone has not been connected to the network once the lock has been activated, remote methods will not work.
💡
Regularly back up important data to the Mi Cloud or Google Photos cloud so that valuable memories are not lost if blocked.
Prevention of blocking and backups
To prevent the situation of “Xiaomi forgot your graphical password” from catching you off guard in the future, it is important to properly configure the security system in advance. Modern smartphones offer biometric methods of protection that are much more convenient than entering passwords. Fingerprint or Face ID settings will allow you to unlock the device in a second.
However, biometrics cannot completely replace the pattern lock, because after a reboot or 72 hours of downtime, the system will still require the primary password to be entered. So it is critical to remember this code, write it down in a secure location or use password managers that are synchronized between devices.
- 📸 Set up automatic uploading of photos in Google Photos or Mi Cloud.
- 🔑 Use simple but not obvious graphic keys that are easy to replicate with muscle memory.
- 💾 Periodically check the health of accounts linked to the phone.
It is also recommended to enable Smart Lock in Android security settings, which allows you to keep your phone unlocked in certain places (such as at home) or when connected to trusted devices (smart watches, Bluetooth headset).
💡
The best protection against loss of access is not a complex password, but regular backup and account binding.
In conclusion, the forgotten password problem is 100% solvable, but the cost of the solution ranges from a few clicks to total data loss. Be careful when installing security codes and use the capabilities of the Xiaomi and Google ecosystem to minimize risk.