How to remove a pattern lock on Xiaomi: official and alternative methods

Forgot the screen unlock combination on Xiaomi? This situation is familiar to many users, especially if the device has been lying idle for a long time or used by relatives. PIN-It's a code that's completely blocked when you lose it, and fortunately, there are formal and informal ways to fix it that work on most Redmi models, POCO and Mi (including Redmi Note) 10/11/12, POCO X3/X4/X5, Mi 11/12).

In this article, we will discuss 5 working methods to remove the pattern lock on Xiaomi, from a standard reset via Mi Account to advanced techniques using ADB and Fastboot. Importantly, some methods lead to data loss, so first try to restore access without drastic measures. If the phone is synchronized with the Xiaomi account, the chances of successful unlock without reset are much higher.

1 Unlocking through Mi Account (official method)

The safest method is if the phone has a Xiaomi account attached and sync enabled. Suitable for devices with MIUI 12 and later, where the Find Device function is active by default, the main condition is that the phone must be connected to the Internet (via mobile network or Wi-Fi).

Instructions:

  • 🌐 Go to account.xiaomi.com and log in with the same account as you do on your phone.
  • πŸ” In the Devices section, find a locked smartphone (if not, update the page or check the phone’s connection to the network).
  • πŸ”“ Press Unlock the screen and follow the system's prompts. The phone will receive a confirmation notification.
  • βœ… Once confirmed, the pattern lock will be reset and the phone unlocked.

Limitations of the method:

  • ❌ It does not work if the phone is disabled sync with Mi Account.
  • ❌ Requires a stable Internet connection on a smartphone.
  • ❌ In some models (for example, POCO F1) Additional confirmation may be required for SMS.

⚠️ Note: If you have previously changed your Mi Account password but haven’t updated it on your phone, unlocking your account may not work.

πŸ“Š What Unlocking Method Have You Tried Before?
Through the Mi Account.
Reset to factory settings
Used ADB.
I went to the service center.
I've tried nothing.

2. Reset the pattern lock via Recovery Mode (with loss of data)

If Mi Account is lost or the phone is not connected to the Internet, the radical method is hard reset via Recovery Mode, which will remove all data from the device, including photos, contacts and apps, but guaranteed to unlock the screen.

Step-by-step:

  1. Turn off the phone with a long press on the power button (if it does not respond, press the Power + Volume Up for 10-15 seconds).
  2. Press the button combination to enter Recovery Mode: For most models: Power + Volume Up. For POCO M3/M4 and some Redmi: Power + Volume Down.

Wipe Data β†’ Wipe All Data

Confirm the reset, wait for the process to complete (5-10 minutes) and restart the phone.

Important: New Xiaomi models (e.g. Redmi Note 12 Pro+) may require data entry from the Mi Account that was previously linked to the phone after a reset, which is a FRP-blocking measure. If you do not remember the username / password, it will be more difficult to unlock the phone - you will need to contact the service center.

Turn off the phone from charging.

Make sure the battery is at least 30% charged.

Prepare a backup of important data (if you have access to a PC)

Remember the data from Mi Account (if the phone is tied)-->

3. Unlock through ADB (for advanced users)

The method is suitable if the phone is enabled debugging by USB (USB Debugging, and you have access to a computer, and it doesn't cause data loss, but it requires command line skills. MIUI 11–14.

What you need:

  • πŸ–₯️ Computer with installed Xiaomi drivers and package ADB Tools.
  • πŸ”Œ USB-cable (preferably original).
  • βš™οΈ Included debugging by USB in the developer settings (if not enabled in advance, the method will not work).

Instructions:

  1. Connect your phone to your PC and open the command line (Win + R β†’ cmd).
  2. Enter the command to check the connection: adb devices If the device is displayed, move on. If not, install the drivers or check the cable.
  3. Delete the file with the pattern lock: adb shell rm /data/system/gesture.key or for newer versions of MIUI: adb shell rm /data/system/locksettings.db
  4. Reboot your phone: adb reboot

After rebooting, the pattern lock will be reset, but may need to be entered PIN-password or code from your Google account (if it has been set up).

⚠️ Note: On some models (POCO X5 Pro, Redmi K50) After removing gesture.key, the phone may become obsessed with booting.

πŸ’‘

If USB debugging wasn’t enabled in advance, try to activate it blindly: connect your phone to your PC, enter your Google account password (if you request it), and click 7 times on the β€œBuild Number” field in the settings, which sometimes works even on a locked screen.

4.Using Fastboot to bypass lockdown

If the ADB is not working or the USB debugging is disabled, you can try unlocking the phone via Fastboot mode. This method is suitable for devices with an unlocked bootloader. If the bootloader is locked, you will need to pre-unlock it through the Mi Unlock Tool, which takes up to 72 hours.

Instructions:

  • πŸ”Œ Connect your phone to your PC in Fastboot mode (press Power) + Volume Down with the device switched off).
  • πŸ–₯️ Open the command line and check the connection: fastboot devices
  • πŸ”§ Enter the command to delete the pattern lock: fastboot erase gesture or for new models: fastboot erase locksettings
  • πŸ”„ Reboot your phone: fastboot reboot

If after restarting the phone still requests a pattern lock, try to perform:

fastboot erase frp

It'll be deleted. FRP-blocking (reset protection), but may cause additional problems with your Google account.

MethodPC requiredLoss of dataDifficultyWorks for MIUI.
Mi Account❌ No.❌ No.⭐ Easy.12–14
Recovery Mode❌ No.βœ… Yes.⭐⭐ Middle-AverageAll versions.
ADBβœ… Yes.❌ No.⭐⭐⭐ Hardly.11–14
Fastbootβœ… Yes.❌ No.⭐⭐⭐⭐ Very difficult.All versions.
Service centre❌ No.❓ Depends.⭐⭐ Middle-AverageAll versions.

5. Contact the Xiaomi Service Center

If you don't succeed on your own, you have to go to the official service center, which is the most reliable, but also the longest way.

  • πŸ”§ Unlocking without risk of damaging your phone.
  • πŸ“„ Preservation of the guarantee (if it is valid).
  • πŸ”’ Data recovery (in some cases).

What will be required:

  • πŸ“„ Passport or document confirming the purchase of the phone.
  • πŸ” Mi Account data if the phone is linked to the account.
  • πŸ’° Payment for the service (cost varies from 500 to 2000 rubles depending on the model).

Where to find a service center:

  • πŸ“ Through the official website of Xiaomi (section "Service centers").
  • πŸ›’ In partner stores (for example, Svyaznoy, M. Video).
  • πŸ“ž Phone hotline: 8 800 775-66-88 (call-off).

⚠️ Warning: Avoid "handicraft" workshops promising to unlock your phone in 10 minutes.Unqualified intervention can cause a motherboard to break or lock IMEI.

What if your phone asks for an old Google account after unlocking?
It's called FRP-To get around it, you need to enter data from the Google account that was linked to the phone before the reset. If you don't remember the password, restore it through the reset. [account.google.com](https://account.google.com/). On some Xiaomi models (e.g. Redmi) 9, POCO M3) FRP You can use special utilities like "FRP Bypass APK", But it requires skill and can compromise the security of the device.

How to avoid data loss in the future

To avoid having a locked phone problem again, follow the simple guidelines:

  • πŸ” Use the backup. PIN-code or password together with pattern lock (setting in Settings) β†’ Lock screen).
  • ☁️ Regularly sync your data with Mi Cloud or Google Drive.
  • πŸ“± Turn it on. USB Debugging in the developer settings (this will help unlock the phone through the ADB future).
  • πŸ“ Write down your graphical key or password in a secure location (such as in Bitwarden or KeePass password manager).

It’s also helpful to set up a Smart Lock on Android so that your phone automatically unlocks in secure places (such as at home or work).This feature is available in Settings β†’ Lock and Protection β†’ Smart Lock.

πŸ’‘

Even if you successfully unlocked your phone, set up a backup login method (PIN or password) right away and check sync with Mi Account.

FAQ: Frequent questions about unlocking Xiaomi

❓ Can I remove the pattern lock without losing data?
Yes, if the phone is debugging over USB (ADB) or is tied to the Mi Account with active synchronization, in which case the data will remain intact, and if none of these methods work, you will have to reset through Recovery, which will lead to the deletion of all files.
❓ Why After Recovery Reset, Your Phone Asks for an Old Mi Account?
This is FRP, which is activated if the phone was linked to a Xiaomi account. To unlock the device, enter the username and password from that account. If you don't remember them, restore access through the official website or contact the service center with documents on the phone.
❓ Does the way with ADB Xiaomi Redmi Note 11?
Yes, but only if USB debugging was enabled before locking.On the Redmi Note 11 with MIUI 13, the command to delete the key is: adb shell rm /data/system/locksettings.db If debugging was not activated, this method will not work.
❓ How much does it cost to unlock in the Xiaomi service center?
The cost depends on the model and the complexity of the work: Redmi 9/10: 800-1200 rubles. POCO X3/X4: 1000-1500 rubles. Mi 11/12: 1500-2500 rubles. In official centers, the price is fixed and includes diagnostics.
❓ Can you unlock Xiaomi through Google’s Find My Device?
No, Google Find My Device does not support unlocking the pattern lock on Xiaomi.This feature only works for devices with pure Android (like Pixel or Nexus).For Xiaomi smartphones, use Mi Cloud or other methods from this article.