How to unlock Xiaomi phone if you forget your graphical password: from Mi Account to Hard Reset

The forgotten graphical password on Xiaomi's smartphone is a situation that thousands of users face every day. PIN-When you use a code or fingerprint, the pattern seems easy to remember until you have to type it after a reboot or prolonged downtime. Fortunately, the manufacturer has provided several official and unofficial ways to return access to the device โ€“ from restore through the Mi Account to a complete reset via Fastboot.

Itโ€™s important to understand that not all methods will save your data. For example, unlocking through Mi Cloud or Find Device can work without loss, while Hard Reset will remove all information from internal memory. In this article, we will discuss all the current ways for models in 2020-2026 (including Redmi Note 12, POCO X5, Mi 13 and others), indicate their pros and cons, and also warn against common errors that can turn a phone into a brick.

1 Unlocking through Mi Account (official method)

The safest method is if you previously linked your device to your Xiaomi account, which works on all smartphones with MIUI 12 and later, including the latest firmware in 2026, and the main condition is that the phone must be connected to the Internet (via Wi-Fi or mobile network).

Algorithm of action:

  • ๐Ÿ”„ On the lock screen, enter the wrong pattern lock 5 times in a row.
  • ๐Ÿ“ง Select the option โ€œForgot the password?ยป โ†’ ยซSign in via Mi Accountยป.
  • ๐Ÿ” Enter the username and password from your Xiaomi account (the same one used for syncing).
  • ๐Ÿ“ฑ After successful authorization, the system will prompt you to create a new pattern lock or PIN-code.

If you do not remember your account data, restore it through the official account.xiaomi.com website.Please note: when you restore your password via email or SMS, you may need to confirm it on another device.

โš ๏ธ Note: If the phone was bought with hands and the previous owner did not untie his Mi Account, this method will not work.

๐Ÿ“Š How often do you use a graphical password?
Always.
Only for important applications
I used to, but I switched to PIN.
Never used it.

2. Use of the โ€œFind Deviceโ€ function (remote unlock)

Find Device (similar to Googleโ€™s Find Phone) not only allows you to track your smartphoneโ€™s location, but also unlock it remotely.

  • ๐Ÿ“ The device is connected to the Internet (Wi-Fi/mobile).
  • ๐Ÿ”„ In the settings enabled synchronization with Mi Cloud.
  • ๐Ÿ”’ You remember the data from the Xiaomi account.

Instructions:

  1. Go to i.mi.com from a computer or other phone.
  2. Sign in with your Mi Account.
  3. In the menu, select the locked device (if there are several).
  4. Click "Unblock" and confirm the action.

After that, the graphical password will be reset and the phone will receive a notification of successful unlocking, which works even if the phone is turned off, but the next time you connect to the Internet, the command will be executed automatically.

๐Ÿ’ก

If Find Device is disabled, turn it on in advance in the settings: Settings โ†’ Mi Account โ†’ Mi Cloud โ†’ Find the device. This will help you avoid unlocking problems in the future.

3. Recovery Mode reset (without data loss on some models)

The method is suitable for devices with unlocked bootloader or models where Xiaomi allows you to reset the graphics password without full cleaning. For example, on Redmi 9/9A or POCO M3 you can do a soft reset, but on flagships (Mi 13 Ultra, Xiaomi 14) this will lead to the deletion of all data.

Step-by-step:

  1. Turn off the phone with a long press on the power button.
  2. Press Volume Up + Power at the same time and hold for 10-15 seconds until the Mi logo appears.
  3. From the Recovery menu, select the language (usually English or Chinese).
  4. Go to Wipe & Reset โ†’ Wipe All Data (on some firmwares, the item may be called Erase User Data).
  5. Confirm the action and wait for the reboot.

If you reset your phone and you want to enter your Mi Account, use a linked account, and you can't unlock your device without it, because it's anti-theft.

โš ๏ธ Note: On devices with a locked bootloader, a reset via Recovery may result in activation FRP-Factory Reset Protection: This will require the username/password from the last Google account you use.

Turn off the phone from charging.

Make sure the battery is at least 30% charged.

Prepare your Mi Account information (if required)

Have your hand on it. SIM-Confirmation card (on some models)-->

4. Unlock via Fastboot (for advanced users)

The way for those who are willing to work with ADB and Fastboot is if:

  • ๐Ÿ”“ Bootloader unlocked on the phone (checked by the fastboot oem device-info team).
  • ๐Ÿ’ป There is a computer with installed Xiaomi drivers and package ADB Tools.
  • ๐Ÿ“‚ There is a backup of the data (the method can erase it).

Instructions:

  1. Download and install Googleโ€™s Platform Tools.
  2. Turn off the phone and put it into Fastboot mode, clamping Volume down + Power.
  3. Connect the device to the PC via USB.
  4. Open the command line in the folder with ADB and type: fastboot oem unlock If the bootloader is locked, first execute: fastboot oem unlock-go
  5. Once you unlock the bootloader, type in: fastboot erase userdata fastboot erase frp fastboot reboot

This method will delete all data, but will bypass the graphical password and Mi Account. New models (Xiaomi 13T, Redmi K60) may require additional confirmation through the official Xiaomi website to unlock Bootloader.

What if the "fastboot oem unlock" command doesn't work?
Some models (e.g., POCO F5) require you to first link your Mi Account to your device via the Mi Unlock Tool. Download the utility from the official website, log in and follow the instructions. The process can take up to 72 hours due to Xiaomi restrictions.

5. Contact the Xiaomi Service Center

If all of the above methods do not work, you need to contact an authorized service center.

  • ๐Ÿ“ฑ Phones with Bootloader locked and Mi Account unknown.
  • ๐Ÿ”’ Devices purchased from hands without the ability to confirm ownership.
  • ๐Ÿ›  Models where resetting leads to FRP-locking (for example, Xiaomi 12 Pro with firmware for the global market).

What will be required to unlock:

Document/conditionalityWhat do you need?Note
Check or sales contractConfirmation of possessionIf the phone is not in your name,
PassportIdentity cardOriginal required
Phone box.Model and IMEI ConfirmationIt is desirable, but not always necessary.
Data from Mi AccountUnblocking a tied accountIf your account is not yours, recovery is not possible.

The cost of the service varies from 500 to 3000 rubles depending on the model and the complexity of the case. Some services offer a โ€œbypassโ€ Mi Account for a fee, but this violates Xiaomiโ€™s policy and can lead to locking the device.

6. How to avoid data loss when unlocking

If you don't want to lose photos, contacts and messages, set up a backup beforehand. Here's what you can do before your phone locks:

  • โ˜๏ธ Enable automatic synchronization with Mi Cloud (Settings) โ†’ Mi Account โ†’ Mi Cloud โ†’ Synchronization).
  • ๐Ÿ“ฒ Use Google Photos to back up your media files.
  • ๐Ÿ’พ Regularly create local backups through Settings โ†’ Additionally. โ†’ Backup and reset.
  • ๐Ÿ”— Link your Google account to help restore contacts and apps after resetting.

If your phone is already locked, but you have it on USB Debugging (debugging by USB), You can try to extract data through ADB:

  1. Connect the phone to the PC.
  2. Open the command line and type in: adb shell rm /data/system/gesture.key or for newer versions of Android: adb shell rm /data/system/locksettings.db
  3. Reset the device.

โš ๏ธ Note: This method only works if the debugging is done USB It was on before the lockdown. MIUI 14 and newer it may not work due to tightened security measures.

๐Ÿ’ก

The most reliable way to save data is to use regular backups in Mi Cloud, and even if you forget your password, files will remain accessible through the web version of the cloud.

FAQ: Frequent questions about unlocking Xiaomi

Can I unlock Xiaomi without losing data?
Yes, but only if: You remember the data from Mi Account and the phone is connected to the Internet, you had sync with Mi Cloud (then the data will recover after unlocking), you previously created a local backup to a memory card or PC. In all other cases, resetting the graphical password will lead to the deletion of user data.
What to do if you forget your password and your Mi Account?
In this case, there are two options: Contact the Xiaomi service center with documents confirming the purchase. Run Hard Reset through Fastboot, but this will delete all data, and on some models will require entering data from the previous Mi Account after a reset. If the phone is bought from hand and the previous owner did not untie his account, you can not unlock it yourself.
Why does the phone ask for an old Mi Account after resetting via Recovery?
This is Anti-Theft. All Xiaomi smartphones with MIUI 10 and later after reset via Recovery or Fastboot require you to enter data from the last associated account. If you do not remember them, contact the service center with proof of purchase.
Can I unlock Xiaomi through my Google Account?
No. Unlike older versions of Android, Xiaomi with MIUI does not support unlocking through a Google account. The only official way is to use Mi Account.
Will unlocking through ADB work if USB debugging wasnโ€™t enabled?
No. Adb shell rm /data/system/gesture.key only works if USB debugging was activated before locking the phone, and it is not possible to turn it on on on a locked device.