The forgotten pattern lock on Xiaomi's smartphone is a situation that even experienced users face. PIN-It's harder to remember the code, especially if you change it rarely or use multiple devices, and fortunately, the manufacturer has provided several formal and alternative unlocking methods that don't require a service center. The main thing is to act carefully so as not to lose important data.
In this article, weβll look at all the current methods for unlocking the pattern lock on Xiaomi, Redmi and POCO devices, including models with MIUI 12/13/14 and older firmware versions. From simple reset via Mi Account to advanced solutions using ADB or Fastboot, youβll find a suitable option even if you donβt remember the username from your account or have never connected your phone to your computer.
Important: some methods lead to a complete cleanup of data (photos, contacts, messages). If your smartphone backs up to Mi Cloud, you can recover some information after unlocking. Before you start, check the battery power - it should be at least 30% to avoid a sudden shutdown during the procedure.
1 Unlocking through Mi Account (official method)
The most secure and recommended method for Xiaomi is to use a tied Mi Account. It works on most devices if:
- π± Smartphone connected to the Internet (Wi-Fi or mobile network).
- π Remember the username and password from Mi Account.
- π The device is enabled synchronization with the account.
If all conditions are met, follow the instructions:
- On the lock screen, enter the wrong pattern lock 5 times in a row, and the message will appear: "Forgot your password?" or "Unlock through Mi Account".
- Click on the link and enter details from your Xiaomi account (email or phone number + password).
- Confirm your login via SMS or email (if two-factor authentication is enabled).
- Create a new pattern lock or PIN-code.
β οΈ Note: If you don't remember the Mi Account password, try to restore it to the official account.xiaomi.com. Use the linked email or phone number. Recovery via backup email takes up to 24 hours.
2. Reset the pattern lock via Find Device (remotely)
Xiaomiβs Find Device feature not only allows you to track your smartphone, but also remotely reset the lock, which is suitable if:
- π The device is connected to the Internet.
- π Find Device is activated in settings (Settings) β Mi Account β Find the device).
- π You are logged in to your Mi Account on another device.
Instructions:
- Go to i.mi.com and log in.
- In the "Devices" section, select a locked smartphone.
- Click "Find the device", then "Unlock".
- Confirm the action via SMS or email.
After that, the pattern lock will be reset, but all the data on the device will remain intact, which works even if the smartphone is turned off, but the next time you connect to the Internet, the lock is removed.
π‘
If Find Device is disabled, enable it in advance in the security settings, which will help unlock the device remotely in the future.
3. Unlock via Recovery Mode (reset to factory settings)
If you don't remember Mi Account data or Find Device is disabled, you'll have a hard reset via Recovery Mode, which deletes all the data on your device, including photos, apps and settings. Use it only as a last resort!
Instructions for most Xiaomi/Redmi/POCO models:
- Turn off the smartphone with a long press on the power button.
- Press the button combination: For most models: Volume up + Power. For older devices (Redmi 4/5, Mi A1): Volume up + Volume down + Power.
Mi
Recovery
Use volume buttons for navigation and power button for selection.
Wipe Data β Wipe All Data
Factory Reset
Confirm the action and wait for the reset to be completed.
Reboot β Reboot to System
β οΈ Note: On some devices with MIUI 12+ After the reset, you may need to enter data from the Mi Account that was previously linked (FRP-If you do not remember the username / password, you will have to use Fastboot or contact the service.
Turn it off. SIM-card and memory card (if any)
Charge your phone to at least 50%
Prepare a backup of important data (if you have access to a PC)
Make sure you know the data from Mi Account (for FRP)
-->
4. Unlock via Fastboot (for advanced users)
The method via Fastboot is suitable if:
- π₯οΈ You have access to a computer with Xiaomi drivers installed.
- π§ You can work with the command line.
- π± The bootloader is unlocked on the device (Bootloader).
If the bootloader is locked, this method will not work β you will need an official unlock through the Mi Unlock Tool (the process takes up to 720 hours of waiting).
Instructions for the unlocked loader:
- Install Android SDK Platform Tools on your PC.
- Turn off your smartphone and put it in Fastboot mode: Volume down + Power
- Connect the device to the PC via USB.
- Open the command line in the folder with the platform-tools and execute the commands: fastboot devices (should display your device) fastboot erase frp fastboot reboot
After the reboot, the lock on the pattern lock will be reset, but the data will remain. If the erase frp command does not work, try:
fastboot erase userdataThis command will result in a complete reset (like in Recovery).
What if the Fastboot canβt see the device?
5. Unlock through ADB (without data loss)
method ADB (Android Debug Bridge allows you to reset the pattern lock without deleting data, but requires pre-activation of debugging USB (USB If you didn't turn on this feature before blocking, the method won't work.
Instructions:
- Connect your smartphone to your PC via USB.
- Open the command line in the folder with platform-tools.
- Follow commands in order: adb shell su rm /data/system/gesture.key rm /data/system/locksettings.db rm /data/system/locksettings.db-wal rm /data/system/locksettings.db-shm reboot
After the reboot, the pattern lock will be reset. If the su command is not working (no root rights), try:
adb shell
cd /data/data/com.android.providers.settings/databases
sqlite3 settings.db
update system set value=0 where name='lock_pattern_autolock';
update system set value=0 where name='lockscreen.lockedoutpermanently';
.quit
rebootβ οΈ Attention: On devices with MIUI 13/14 Android 12+ This method may not work because of the increased protection, in which case try Fastboot or Recovery reset.
Comparison of methods of unlocking the pattern lock Xiaomi
| Method | Conditions required | Data retention | Difficulty | Implementation time |
|---|---|---|---|---|
| Mi Account | Internet, account data | β Yes. | β | 2-5 minutes |
| Find Device | Internet, Mi Account, enabled function | β Yes. | β | 5 minutes. |
| Recovery Mode | Access to buttons | β No (full reset) | ββ | 10 minutes. |
| Fastboot | PC, unlocked bootloader | β οΈ Partially (depends on the team) | βββ | 15-30 minute |
| ADB | PC, enabled debugging over USB | β Yes. | ββββ | 20 minutes. |
π‘
The most reliable ways are Mi Account and Find Device, which require no technical skills and store data, and the methods through Fastboot and ADB are only suitable for advanced users.
Frequent Mistakes and How to Avoid Them
When you unlock a pattern lock, users often face typical problems, and here are the most common ones and solutions:
- π "Fastboot doesnβt see the deviceβ: Check the cable (use the original from Xiaomi), install drivers manually or try another one USB-On some PCs, disabling driver signatures helps.
- π "After reset, requires an old Mi Account: This FRP-If you don't remember your account details, try to restore them to account.xiaomi.com or use Fastboot to delete them. FRP.
- βοΈ "ADB It gives you a 'device unauthorized' error: So you haven't previously confirmed that you're connecting this PC to a smartphone.
- π΅ "Sensor fails after failed reset": This may be due to firmware damage. Try reflashing the device via Mi Flash Tool (requires unlocked bootloader).
β οΈ Note: If after unlocking the Xiaomi smartphone constantly restarts or does not turn on, most likely, the system partition was damaged.