How to reset your Xiaomi smartphone to factory settings via PC: 3 proven ways

Why do you need a PC reset and when it is the only solution

Xiaomi's factory reset via a computer is not just an alternative to the standard method through the phone's menu, but often the only way out of a crisis: Imagine if the screen is locked after a failed firmware, the device is getting stuck on the Mi logo or does not respond to touch, in which case the connection to the PC becomes a lifeline.

The main scenarios when reset via a computer is necessary:

  • πŸ”’ Forgotten graphical key or password – if you have exhausted all attempts to unlock and your Mi Account is not tied;
  • 🐒 System lags and freezes – when the phone turned into a β€œbrick” after updating or installing custom firmware;
  • πŸ“± Preparation for sale – complete data cleanup without risk of recovery by the previous owner;
  • πŸ”„ Removing viruses or malware that block access to settings.

It’s important to understand that PC resets are not a universal go-to. They have limitations and risks. For example, some Xiaomi models (especially those with MediaTek processors) may require authorization for a Mi Account even after a reset, and on devices with a locked bootloader, the procedure is not possible without first unlocking.

πŸ“Š Why you want to reset Xiaomi via PC?
Forgot my password.
Phone's bugging.
I'm getting ready to sell.
Other causes

Resetting Preparation: What to Do Before Connecting to a PC

Before you jump into battle, prepare a battlefield, and doing the wrong thing at this point can turn your Redmi or POCO into a useless piece of plastic.

Make sure the battery is charged > 50%|Download the official drivers Xiaomi|Prepare. USB-cable (original!)|Save important data (if the phone is still working)|Disable antivirus on PC

-->

1. Battery check. Minimum threshold is 50%. If the phone runs out during the procedure, there is a high risk of damage to the firmware. On models with a fixed battery (for example, Xiaomi 13 Pro), this is especially critical.

2. Install drivers. Without them, your PC won't see your device in the right mode.

  • πŸ–₯️ Xiaomi drivers for your model;
  • πŸ”Œ ADB Fastboot (part of Android) SDK Platform-Tools).

⚠️ Warning: On Windows 11, drivers can be blocked by security. Before installation, temporarily disable driver signature verification via gpedit.msc β†’ User configuration β†’ Administrative templates β†’ System system β†’ Installation of the driver.

3. Cable selection. Use the original USB-Xiaomi cable or certified cable USB Type-C with data support. Cheap Chinese cables often don't transmit commands in Fastboot mode.

Xiaomi modelType of connectorFeatures of connection
Redmi Note 10/11USB Type-CRequires confirmation of debugging over USB at the first connection
POCO F3/F4USB Type-CSensitive to cable quality – may not be defined in Fastboot
Xiaomi 12/13 seriesUSB Type-C 3.1Supports high-speed mode, but USB 2.0 is enough to reset
Redmi 9A/9CMicro-USBFrequent problems with the definition of EDL-mode

Method 1: Reset via Mi Flash Tool (official method)

Mi Flash Tool is a Xiaomi-branded firmware and reset utility that works even with locked phones, but requires bootloader pre-unlocking. If you've never unlocked a bootloader on your Xiaomi, it's not going to work, you'll have to use alternative methods.

Step-by-step:

  1. Download the Mi Flash Tool (version no lower than 2023.4.1).
  2. Unpack the archive with the firmware for your model (.tgz or.zip format).
  3. Turn off the phone and put it in Fastboot mode: pinch Power + Volume down for 10 seconds.
  4. Connect the device to a PC. Android Bootloader Interface should appear in the Device Manager.
  5. In the Mi Flash Tool, click Select, specify the path to the unpacked firmware, then select Clean All mode (full reset).
  6. Press Flash and wait until it is completed (usually 5-10 minutes).

What if the Mi Flash Tool can't see the phone?
1. Check if Qualcomm drivers are installed HS-USB QDLoader 9008 (for mode) EDL). 2. Try another one. USB-port (preferably on the back of the PC). 3. Disable all other USB-Devices – they may conflict. 4. Reinstall drivers manually through Device Manager, pointing the path to the folder with the Mi Flash Tool.

⚠️ Note: On models with a MediaTek processor (e.g. Redmi) 10C or POCO M4 Pro) Mi Flash Tool only works in mode EDL, which requires authorization through the Mi Account. Without it, reset is impossible!

Advantages of the method:

  • βœ… It even works on β€œbricks” (devices with damaged firmware);
  • βœ… Complete cleaning of all sections, including /data and /cache;
  • βœ… The ability to select a firmware version (for example, transition from MIUI Globally MIUI EU).

Disadvantages:

  • ❌ Requires an unlocked bootloader;
  • ❌ Difficult for beginners (risk of choosing the wrong firmware);
  • ❌ On some models, washing IMEI, if conditions are not met.

πŸ’‘

Mi Flash Tool is the most reliable way to reset, but it is only suitable for devices with an unlocked bootloader.

Method 2: Reset via ADB (without data loss in some cases)

If your Xiaomi is still on, but you can’t get into the settings (for example, because of the pattern lock), ADB (Android Debug Bridge) can be a rescue, which allows you to reset directly from the system without resorting to firmware.

What you need:

  • πŸ–₯️ Established ADB and Fastboot;
  • πŸ”Œ Included debugging by USB on the phone (if the phone is still working);
  • πŸ“± Access to the developer menu (activated by 7-fold tap on the version) MIUI customized).

Instructions:

  1. Connect your phone to your PC and confirm debugging over USB on the device screen.
  2. Open the command prompt in the folder with platform-tools (click Shift + right mouse button β†’ Open the PowerShell window here).
  3. Enter the command to check the connection: Adb devices must appear serial number of your device.
  4. Reset one of the commands: adb shell recovery --wipe_data or (for new versions) MIUI): adb shell am start -a android.intent.action.MASTER_CLEAR

πŸ’‘

If the command doesn’t work, try getting root rights first through adb shell su (requires an unlocked bootloader).

When this method works:

  • πŸ”“ Phone is on but locked with pattern lock;
  • πŸ“΅ You need to reset the settings without losing data in /sdcard (photo);
  • πŸ”„ Partial reset is required (e.g., app cache only).

⚠️ Attention: MIUI 14 newer MASTER_CLEAR It might not work because of security constraints, and then you'd have to use a Fastboot.

Method 3: Reset via Fastboot (universal method)

Fastboot is a bootloader mode that allows you to control the device at a low level. Unlike the Mi Flash Tool, it does not require unlocking the bootloader to reset (but unlocking is necessary for firmware), This method is suitable for 90% of Xiaomi models, including Redmi, POCO and Black Shark.

Step-by-step:

  1. Turn off the phone.
  2. Press Power + Volume down before the Fastboot logo appears (Android robot with an open belly).
  3. Connect the device to the PC and check its availability with the command: fastboot devices
  4. Reset one of the commands: fastboot erase userdata or (for a complete reset): fastboot -w
  5. Reboot the phone: fastboot reboot

What each team erases:

Team team.What's removedWhether /sdcard is retained
fastboot erase userdataAll user data and settingsYes.
fastboot -wUser data + cacheYes.
fastboot erase systemSystem partition (leads to a "brick" without firmware!)No.

The advantages of Fastboot:

  • ⚑ Works on locked devices (unless firmware is required);
  • πŸ”§ It does not require a full download;
  • πŸ› οΈ You can combine with other commands (e.g., fastboot flash recovery for recovery). TWRP).

How to get out of Fastboot if the phone is getting stuck?
If the phone does not restart after fastboot reboot, press the power for 20-30 seconds to force it to turn off.

Frequent mistakes and their solutions

Even with the right instructions, something can go wrong, and here are the most common mistakes and ways to correct them:

1. Waiting for device error in ADB/Fastboot

  • πŸ”Œ Check the cable and port USB (try USB 2.0 instead of 3.0);
  • πŸ–₯️ Reinstall drivers manually through Device Manager;
  • πŸ”„ Restart your PC and phone;
  • πŸ› οΈ Disable the driver signature in Windows (see Preparation section").

2. "Remote: Unknown Command" error in Fastboot

  • πŸ“± Make sure the phone is actually in Fastboot mode (screen with robot);
  • πŸ”„ Try another version of platform-tools (e.g. 33.0.3 instead of 34.0.0);
  • πŸ”§ Use the full path to the command (e.g..\fastboot.exe) -w).

3.After reset, the phone requires a Mi Account

  • πŸ”’ It's FRP-Factory Reset Protection: Enter data from the last Mi Account you have linked to; if you don't remember, use access restoration; some models are supported by firmware through the EDL shut-off FRP (requires an authorized account).

4.The telephone shall not be switched on after discharge

  • πŸ”‹ Connect to charging for 30 minutes - maybe the battery is dead;
  • πŸ“± Try to get into the Fastboot (Food). + Volume down) and run your phone through the Mi Flash Tool;
  • πŸ› οΈ If the screen is black, the PC defines the device as Qualcomm. HS-USB QDLoader 9008, so the phone is in mode EDL β€” You will need an authorized firmware.

πŸ’‘

Most PC reset errors are caused by drivers or cable. Always start diagnosing them!

What to do after resetting: the initial setting

After a successful reset, your Xiaomi has become a blank slate, and you need to set it up properly to avoid problems in the future.

First inclusion:

  • 🌍 Choose a region (Russia or Europe) MIUI Global);
  • πŸ“Ά Connect to Wi-Fi (required to activate Google services);
  • πŸ”‘ Skip Mi Account binding if you don’t plan to use branded services (e.g. Mi Cloud).

System optimization:

  • πŸ”„ Turn off automatic updates MIUI In Settings β†’ The phone. β†’ Updating the system;
  • πŸ“΅ Remove unnecessary system applications through Settings β†’ Applications (e.g. Mi Video, Mi Music);
  • πŸ”‹ Activate the Performance Mode in Settings β†’ Battery β†’ Power regimens.

Data recovery:

  • πŸ“ Transfer files from the PC through MTP (Put your phone on like a flash drive);
  • ☁️ Restore backup from Google Drive or Mi Cloud;
  • πŸ”„ If you've used TWRP, Restore the backup via Restore.

If the screen is completely black and the phone is not detected in either ADB or Fastboot, you will need to repair or firmware via EDL (qualified users only!).

Will these methods reset data on a memory card (SD-card)?
No, in most cases, the data on the SD card remains intact. Exceptions: If the memory card was encrypted in the phone settings; If you manually formatted the SD card via Fastboot (fastboot erase sdcard command); On some models with a MIUI 12+, the memory card may be linked to the Mi Account.
Can you reset Xiaomi via PC on Mac or Linux?
Yeah, but with some nuances: 🍎 On Mac: Install Homebrew; Run brew install android-platform-tools; Xiaomi drivers on Mac are not required, but you may need permission to access the device in System Settings β†’ Security. 🐧 On Linux: Install adb and fastboot via a package manager (e.g. sudo apt install adb fastboot); add a rule for USB-devices: echo 'SUBSYSTEM=="usb", ATTR{idVendor}=="2717", MODE="0666"' | sudo tee /etc/udev/rules.d/51-android.rules Reboot the PC. All teams. ADB Fastboot works the same on all OSes.