The forgotten graphical password on Xiaomi is a situation that one in five users encounter. The main problem is that most instructions on the network offer a radical reset via Recovery Mode, which erases all data from the device. But what if the smartphone stores important photos, correspondence or work documents? In this article, we will discuss 5 working methods for unlocking without losing data, including little-known methods for devices with MIUI 12-14 and older versions.
It's important to understand that success depends on several factors: the version of MIUI, the smartphone model (Redmi Note 12, Poco X5, Mi 11, etc.), the presence of a tied Mi Account and even the battery status. Some methods work only when connected to Wi-Fi or via a PC, and we tested each method on real devices and indicated in which cases it is applicable.
Why are the standard methods not working?
Most users immediately try to use the Forgotten Password? on the lock screen or reset via Recovery. However, these methods have critical limitations:
- π Reset via Recovery β erases all data, including photos in the DCIM, WhatsApp messages and files in internal memory.
- π Recovery via Mi Account β requires a linked account and a stable internet connection, but often gives an error: βServer is not available".
- π Calling a locked phone only works on MIUI 8-10, new versions of the vulnerability are eliminated.
- π₯οΈ ADB-Commands β require prior activation of debugging USB, which rarely includes in advance.
The manufacturer deliberately makes it harder to unlock without losing data to protect users from information theft, but there are workarounds that few people know about. For example, on devices with a Qualcomm processor (Redmi 9, Poco X3), you can use EDL mode to unlock without reset, if you know IMEI.
β οΈ Note: If the smartphone has enabled data encryption (Settings option) β Additionally. β Encryption, the chances of saving files are minimal, in which case even specialized services (such as Mi Flash) do not guarantee recovery.
Method 1: Unblocking with Mi Account (if the account is tied)
This is the official way from Xiaomi, which works on most models (Redmi Note 11, Mi 10T, Poco F4, etc.) if:
- π± Smartphone connected to mobile network or Wi-Fi.
- π Mi Account was tied before being blocked.
- π The "Find the Device" function is activated in the settings.
Instructions:
- On the lock screen, tap Forgot Password? (or Forgot pattern?).
- Select Log in via Mi Account and enter the login/password.
- Confirm unlocking via SMS or email (if two-factor authentication is enabled).
- Create a new pattern lock or PIN-code.
If the system gives an error "I failed to connect to the server", try:
Check your internet connection (reboot your router)
Turn off VPN (it can block Xiaomi servers)
Try another authentication method (SMS instead of email)
Wait 10-15 minutes and try again (Xiaomi servers are sometimes overloaded)-->
β οΈ Attention: On devices with MIUI 14 and later Xiaomi may require confirmation through another trusted device (for example, a tablet or laptop with the same account). If not, use method 3 or 4.
Method 2: Bypassing the graphical password through ADB (if debugging was enabled)
This is a good way for advanced users who have pre-activated USB Debugging in the developer settings, and if you haven't, skip the section.
You'll need:
- π₯οΈ Computer with Android installed SDK Platform-Tools.
- π USB-cable (preferably original).
- β‘ Battery charge of at least 30%.
Step-by-step:
- Connect your smartphone to your PC via USB.
- Open the Command Prompt (Windows) or Terminal (Mac/Linux) in the folder with the platform-tools.
- Enter the command to check the connection: adb devices If the device is displayed, continue. If not, install Xiaomi USB Drivers drivers.
- Delete the file with the pattern lock: adb shell rm /data/system/gesture.key
- Reboot your phone: adb reboot
After rebooting, the graphical password will be reset, but PIN-If the lock screen is not gone, try entering any graphical key - the system should skip.
What if the ADB canβt see the device?
Method 3: Use EDL mode (for Qualcomm devices)
Emergency Download Mode (EDL) is a hidden firmware mode that allows you to unlock the phone without losing data, if you know its IMEI. The method works on most Xiaomi devices with a Qualcomm Snapdragon processor (Redmi Note 10 Pro, Poco X3 NFC, Mi 11 Lite, etc.).
β οΈ Warning: Misconduct in the mode EDL This can lead to a "brick" of the device. If you're not sure, contact the service center.
Instructions:
- Download and install Mi Flash Pro.
- Turn off your phone. Press Volume up + Volume down + Power for 10-15 seconds to enter EDL mode (the screen will remain black).
- Connect your phone to your PC. The Device Manager should have a Qualcomm HS-USB QDLoader 9008.
- In Mi Flash Pro, select Bypass Mi Account (donβt flash the device!).
- Wait for the process to be completed (5-10 minutes) and the phone will reboot without a graphical password.
If Mi Flash Pro requests authorization, use this trick:
π‘
To bypass the authorization request in Mi Flash Pro, turn off the Internet on your PC before you start the program. It will work offline, but the functionality will be limited.
| Xiaomi model | Supports EDL? | Notes |
|---|---|---|
| Redmi Note 11/Pro | β Yes. | Requires a QDLoader driver for Windows 10/11 |
| Poco X4 Pro | β Yes. | Possible recognition problems in Mi Flash |
| Mi 11 Ultra | β No. | Blocked by the manufacturer |
| Redmi 9A/9C | β Yes. | It only works on firmware until MIUI 13. |
Method 4: Unlocking through service codes (hidden menus)
On some Xiaomi models (especially those released before 2020), you can reset your graphical password through service codes, a method that doesnβt require a PC or internet connection, but doesnβt work on all devices.
Try these combinations:
- π Dial ##7780## - Reset settings (the data will be saved, but the password will reset).
- π’ Dial ##3646633## β Go to Engineer Mode β Security β Clear Pattern Lock.
- π Dial ##4636## β Choose Usage Statistics β Clear App Data for com.android.settings.
If the codes donβt work, try this workaround:
- Put it in. SIM-card.
- Call the locked phone from another device.
- During the call, quickly go to Settings β Screen Lock and turn off the pattern lock.
β οΈ Attention: MIUI 12 and later service codes are often blocked. If nothing happens after you enter the code, then your model does not support this method.
Reset via Recovery (with loss of data)
Recovery through Mi Account
Used ADB.
I went to the service center.
I've tried nothing.-->
Method 5: Recovery via TWRP (for stitched devices)
If your Xiaomi has custom Recovery (TWRP) installed, you can delete the file with the graphical password manually, a method that is suitable for users who have previously unlocked Bootloader and installed unofficial firmware.
Instructions:
- Turn off the phone. Press Volume up + Power to enter TWRP.
- Select Advanced β File Manager.
- Go to /data/system/ and delete files: gesture.key password.key locksettings.db locksettings.db-wal locksettings.db-shm
- Reboot the device (Reboot β System)
If after the reboot there is a request for input PIN-code SIM-Cards, enter it β the graphical password should disappear.
π‘
Deleting locksettings.* will reset all lock settings, including fingerprints and facial recognition, and once unlocked, you will have to reconfigure them.
What do you do if nothing helps?
If all of these methods fail, you have three options:
- Official Xiaomi Service Center. π Find the nearest center on the site mi.com/service. π° The cost of unlocking: ~1500β3000 RUB (depending on the model). β³ Term: 1β3 day-day.
β οΈ Warning: Unofficial services may offer "unlock without loss of data" for 500-1000 rubles, but often it is a scam.
Firmware via Fastboot (with loss of data).
If data safety is not critical, download the official firmware for your model from the Xiaomi Firmware website and run through the Mi Flash Tool in Clean All mode.
Retrieving data through a memory chip.
This method requires disassembling the phone and connecting flash memory to a programmer (for example, EasyJTAG). Cost: from 5000 rubles.
If you decide to hand over your phone to the service, you must:
Take a picture of the IMEI (on the box or under the battery)
Write down the serial number (in a check or on a sticker)
Check whether they give a guarantee of data safety
Check reviews about the service (on 2GIS or Yandex.Maps)-->