Reinstall Android on Xiaomi smartphones: a full guide from preparation to firmware

Reflashing Xiaomiโ€™s smartphone is a daunting task, and a properly executed Android reinstallation can solve a host of problems, from system freezes to recovery from a failed upgrade, and in this article, weโ€™ll look at all the steps in the process, from preparing the device to choosing the right firmware and installing it.

It is important to understand that the procedure is different for different models Xiaomi, Redmi and other models. POCO. For example, flagship devices like the Xiaomi 13 Ultra require one approach, and the budget Redmi Note 12 requires another, and we focus on the universal steps, but also point out the key differences for popular lines. If you have never done firmware before, donโ€™t worry: if the instructions are followed, the risk of "bricking" the device is minimal.

Before you start, ask yourself why you need it, and maybe you can solve it in a simpler way, by resetting to factory settings or updating through Settings. โ†’ The phone. โ†’ Update MIUI. The re-flashing is justified if:

  • ๐Ÿ”„ The device is constantly restarted or crashes into fastboot
  • ๐Ÿ“ฑ You want to install custom firmware (like LineageOS or Pixel Experience)
  • ๐Ÿ”’ Phone locked with pattern lock, Find My Device doesn't help
  • ๐Ÿ“‰ Productivity fell after the update MIUI
๐Ÿ“Š What Xiaomi model are you going to try?
Redmi Note 10/11/12
POCO F3/F4/F5
Xiaomi 12/13/14
Another model
I haven't decided yet.

1. Preparation for flashing: what to do in advance

The first and most important step is data backup, and reinstalling Android removes all user files, including photos, contacts and messages, and even if you plan to use the Mi Cloud feature, you better be safe:

  • ๐Ÿ“ Copy photos and videos to your computer or cloud (Google Photos, Yandex Drive)
  • ๐Ÿ“ž Export contacts to.vcf file via Contacts app
  • ๐Ÿ’ฌ Keep your message history with the help of SMS Backup & Restore (available on Google Play)
  • ๐ŸŽฎ If you play games with an account binding, check the synchronization of saves.

The next step is to check the device model and current version. MIUI. This is critical, as the firmware for the Redmi Note 11 Pro (veux) is not suitable for the Redmi Note 11 Pro.+ 5G (You can get a code name:

  1. Enter the phone combination ##4636##
  2. Go to Settings. โ†’ The phone. โ†’ Version. MIUI and tap 7 times on the core line
  3. Use the Device Info app HW (Model Number shows up)

Also make sure that the device has enough battery power of at least 60%, and if the phone runs out during firmware, it can cause serious failures, plug it into the charger or use Power Bank.

๐Ÿ’ก

If you are running a device with a connector USB-C, Use the original Xiaomi cable. Cheap analogues can cause errors in data transfer.

2 Unlock the bootloader: why it is necessary and how to do it

By default, all Xiaomi smartphones have bootloader blocked, a security measure that prevents unofficial software from being installed. To reflash the device, the bootloader must be unlocked, except for the update via Recovery with the official firmware without changing the region.

The unlocking process includes several stages:

  1. Linking your Mi Account to your device (required!)
  2. Application for Unlocking via Mi Unlock Tool
  3. Waiting for confirmation (usually) 7-14 day-to-day)
  4. Unlock directly through Fastboot

Important: Xiaomi has tightened the rules since 2023, and now it requires:

  • ๐Ÿ“ฑ The device must be linked to the Mi Account for at least 30 days
  • ๐Ÿ”— The account must have a confirmed linking of the phone number
  • ๐ŸŒ The account region must match the device region (e.g. Russia for Redmi with global firmware)

If you bought the phone with your hands, make sure the previous owner untie his account, otherwise unlocking will not be possible without his participation.

Link the device to your Mi Account|Confirm the phone number in the profile|Download Mi Unlock Tool from the official website|Enable debugging on USB unlock OEM|Wait 30 days (for new accounts)-->

โš ๏ธ Attention: Unlocking the bootloader resets the device to factory settings. All data will be deleted, even if you haven't started firmware!

3. firmware selection: official MIUI vs custom builds

The type of firmware that you use depends on the functionality, the stability, and even the battery life, and you have three basic options:

Type of firmwarePlusesConsWho's right for?
Official MIUI (Stable/Beta)Maximum compatibility, OTA-Update and support all functionsAdvertising in system applications, restrictions MIUIFor newcomers who want a stable job
Global/European MIUIWithout Chinese services, Google support, less advertisingIt may not support some regional functionsUsers from Europe/Russia with Chinese devices
Brush firmware (LineageOS, Pixel Experience)Clean Android, no ads, regular updatesThe camera may not work, NFC or gestures, no. OTAEnthusiasts ready for experimentation

For most users, the best choice is the official global firmware, which can be downloaded from the Miui Download website.

  • ๐Ÿ“Œ Device code name (e.g. tucana for Redmi Note 8 Pro)
  • ๐Ÿ“… Android Version (12, 13 or 14)

If you decide to install custom firmware, check its compatibility on the forum XDA Developers or 4PDA. Popular builds for Xiaomi:

  • ๐Ÿ”ง Havoc-OS โ€“ for lovers of fine tuning

โš ๏ธ Attention: Castom firmware often requires additional manipulation, such as installing GApps (Google services) and Magisk root-rights kernels. Without them, Play Market, Gmail and other applications will not work.

4. Ways to reinstall Android on Xiaomi

Depending on the purpose and condition of the device, you can choose one of four firmware methods, each with its own characteristics and level of complexity:

  1. Update via Recovery (the safest way)
  2. Firmware via Fastboot (universal method)
  3. Installation through EDL (for brick-and-brick devices)
  4. Custom recovery (TWRP) (custom-fix)

Let's look at each one in more detail.

Update via Recovery (for official firmware)

This method is suitable if you want to update or reinstall the official MIUI The main condition is that the firmware must be the same version or newer than the current one.

Instructions:

  1. Download the firmware in.zip format and rename it to update.zip
  2. Move the file to the root directory of internal memory
  3. Turn off your phone and press Volume Up + Power to Enter Recovery
  4. Choose Install. update.zip to System
  5. Confirm the installation and wait for completion

This method does not reset user data, but it is better to make a backup anyway.

Firmware via Fastboot (universal method)

Fastboot is suitable for installation of official and some custom firmware. You will need a computer with drivers installed. ADB and Fastboot.

Step-by-step:

  1. Unpack the downloaded firmware (should be files with the.img extension)
  2. Connect your phone to your PC in Fastboot mode (clip Volume Down + Power)
  3. Open the command line in the firmware folder and type: fastboot flash boot boot.img fastboot flash recovery recovery.img fastboot flash system system.img fastboot flash vendor vendor.img fastboot reboot

A script can be used to simplify flash_all.bat (If it's in the firmware archive, just run it on behalf of the administrator.

What if Fastboot doesnโ€™t see the device?
Make sure that the debugging is enabled USB In Settings โ†’ For developers, install Mi Flash Tool or Google drivers. USB Driver. Try another one. USB-port (preferably) USB 2.0).

4.3. Firmware through EDL (brick-for-brick")

Regime. EDL (Emergency Download Mode โ€“ the last chance to bring the device back to life if it does not turn on or stuck on the Mi logo (EDL cable) or circuit of the circuit board.

The process requires:

  • ๐Ÿ–ฅ๏ธ Mi Flash Tool or QFil
  • ๐Ÿ”Œ Original. USB-cable
  • ๐Ÿ“„ Firmware in.tgz or.mbn format
  • ๐Ÿ”ง Knowledge of working with Qualcomm or Mediatek chips

โš ๏ธ Attention: Firmware through EDL Without an authorized Xiaomi account, the device may be blocked.New models (2022 and later) require official access.

Installation through TWRP (custom-fix)

TWRP (Team Win Recovery Project is a custom recovery that allows you to install informal firmware, make backups and get root rights:

  1. Unlock the loader
  2. Download the image TWRP for your model
  3. Install it with Fastboot: Fastboot Flash Recovery twrp.img fastboot boot twrp.img

After installation TWRP You can flash.zip files of firmware, Magisk kernels and Xposed modules.

5. Common Mistakes and How to Avoid Them

Even when following the instructions, users often encounter problems, and here are the most common mistakes and solutions:

Mistake.Reason.Decision
This package is for "veux" devices; this is a "peux"Inconsistency of the firmware modelDownload the firmware for the correct device code
Couldn't verify device for flashingUnlocked loaderUse the Mi Unlock Tool to unlock the device
The device is stuck on the Mi logoIncorrect firmware or interrupted processRepeat the firmware via Fastboot or EDL
E: Footer is wrong in TWRPA damaged firmware fileDownload the firmware and check the checksum MD5

If the device does not turn on after firmware, try:

  • ๐Ÿ”‹ Connect to charging for 30 minutes (sometimes helps with a discharged battery)
  • ๐Ÿ”„ Go to Fastboot and repeat the firmware
  • ๐Ÿ“ก Use the Mi Flash Tool with the Clean All option

Critical information: on devices with a Mediatek chip (e.g. Redmi) 10C or POCO M4 Pro) Fastboot firmware may result in flash memory locking. For them, it is recommended to use only the official Mi Flash Tool with authorization.

6.What to do after reinstalling Android

Successful firmware is only half the battle, and after the first boot of the device, you need to follow a few important steps:

  1. System setup: Go through the initial configuration, connect to Wi-Fi, and log in to your Mi Account (if required).
  2. Functionality check: Make sure the camera, sensors, mobile network and Wi-Fi are working.
  3. Data recovery: Move files from the backup, restore contacts and applications.
  4. Security Update: Check for updates in Settings โ†’ The phone. โ†’ Update MIUI.

If you have installed custom firmware, you may additionally need to:

  • ๐Ÿ”‘ Installation of Magisk for root rights (via TWRP)
  • ๐Ÿ“ฑ Setting up GApps (if not included in the firmware)
  • ๐Ÿ”’ Disabling the verification of signature in TWRP (if the firmware is not certified)

It is also recommended to calibrate the battery after firmware:

  1. Charge your phone to 100%
  2. Turn off the charging and use until completely discharged.
  3. Repeat the cycle 2-3 times

๐Ÿ’ก

After the firmware, take your time to recover data from the backup. First, make sure that the system is stable without additional applications.

7. Alternative methods: when firmware does not help

If reinstalling Android didn't solve the problem, it might be the hardware part.

Problem.Possible causeDecision
The phone does not turn on after the firmwareThe loader or flash memory is damagedSqueeze through EDL Using the Mi Flash Tool
Continuous resetsIncompatibility of the kernel or modulesInstall another version of the firmware or kernel
The sensor or display is not working.The plume or controller is damaged.Contact the service center
Not catching the net.Modem drivers missingSweat separately modem.img and vendor.img

If you suspect a hardware malfunction, check:

  • ๐Ÿ”‹ Battery condition (blown, fast discharge)
  • ๐Ÿ“ถ Mobile network antennas (especially after crashes)
  • ๐Ÿ”Œ Charging connector (oxidation, pollution)

For diagnosis, you can use the engineering menu:

  1. Enter the phone combination ##4636##
  2. Go to Testing and check all sensors
  3. Use the app. CPU-Z iron-test

โš ๏ธ Warning: If the phone stops turning on after falling or getting moisture, the firmware will not help.

FAQ: Answers to Frequent Questions

Can I re-flash Xiaomi without unlocking the bootloader?
Yes, but only through Recovery with official firmware. For custom firmware or firmware via Fastboot, unlocking is mandatory.
How long does it take to get through Fastboot?
Usually. 5-15 minutes depending on the size of the firmware and speed USB-The firmware through the port EDL may take up 30 minute.
Will I lose my warranty after unlocking the bootloader?
Yes, unlocking the bootloader and installing custom firmware removes the device from the warranty, but official firmware through Recovery does not cancel the warranty.
How to return the official firmware after custom?
You need to download the official firmware in Fastboot format and flash it through the Mi Flash Tool with the Clean All option.
Can I use Xiaomi on Mac or Linux?
Yes, but you'll need to install ADB and Fastboot via Homebrew (Mac) or Package Manager (Linux.