Installing custom recovery is a key step in the modification of the smartphone, opening the owners of Xiaomi devices the opportunity to create full backups, obtain superuser rights and install alternative operating systems. The Win Recovery Project (TWRP) is the de facto standard in the world of Android-modding due to its convenient interface and extensive hardware support. The process requires care, as interference in the system partition can lead to the inoperability of the gadget in violation of the sequence of actions.
Before proceeding with technical manipulations, it is necessary to realize that unlocking the bootloader and subsequent firmware of third-party software cancel the official manufacturer's warranty. Modern Mi and Redmi smartphones are equipped with a reliable security system that can not be avoided by simply connecting a cable. USB-cable and stable Internet connection for account verification.
In this tutorial, we will discuss in detail each stage of preparation, the process of unlocking Bootloader and directly installing TWRP via Fastboot. Following the algorithm will avoid common errors such as data loss or βbrickingβ of the device.
Workplace preparation and necessary tools
The success of the operation depends on 90% of the quality of the environment. You will need a computer running Windows (versions 7, 10 or 11), which has the ADB and Fastboot drivers installed. Without these components, the PC will not be able to correctly recognize the smartphone in boot mode. You also need to download the image file of the Recovery, which should strictly correspond to the model of your device, since the firmware from Xiaomi Mi 9 will not work for the Xiaomi Mi 10.
Be sure to back up all important data, as unlocking the bootloader results in a complete reset of the device to factory settings. Wipe data is a standard Android security procedure that cannot be bypassed. Copy photos, contacts and documents to an external medium or to cloud storage.
β οΈ Warning: Make sure the battery is at least 60% battery power. Interrupting the firmware process due to battery discharge can lead to irreversible damage to the software part of the device.
To work, you will need to download the archive with the platform tools SDK Platform-Tools from the official Android developer site. Unpack the archive in the root of the C disk for ease of working with the paths. The image file TWRP (usually has the extension.img) put in the same folder, so as not to search it through the command line.
π‘
Use the original. USB-The cable that came with the kit, or the quality analogue with thick wires. Cheap charging cables often do not support data transmission, which will lead to connection errors in Fastboot mode.
Unlock the bootloader with the Mi Unlock Tool
Without unlocked Bootloader, you canβt install a modified recavator. First, activate the developer mode on your smartphone: go to Settings β About Phone and quickly click on the MIUI version seven times. After that, the βFor Developersβ option will appear in the βAdditionalβ menu.
Two critical options must be included in the developer menu: OEM unlocking and USB debugging. Once these functions are enabled, link the device to your Mi Account: click the bootloader status button on the bootloader menu, which triggers a wait timer that can range from 7 to 168 hours (7 days) depending on the region and company policy.
- π Download the official Mi Unlock Tool from the site miui.com/unlock.
- π Connect the smartphone in the off state by clamping the buttons Volume Down + Food before the appearance of the Fastboot logo (hare in the hat).
- π Sign in to Mi Unlock Tool under the same account as on your phone and click the Unlock buttonΒ».
If the waiting timer has not expired, the program will report this and specify the exact time when you can try again. Once successfully unlocked, the device will automatically restart and perform a data reset, which is normal security behavior.
Launching the smartphone in Fastboot mode
To run a recovery, the device must be in a special Fastboot boot mode. Unlike the Recovery mode we're going to install, Fastboot allows you to interact with low-level partitions directly through the computer, which you can log in to either software or hardware.
The hardware method is the most reliable. Turn off the smartphone completely. Then press and hold the volume button. Without releasing the volume button, press the power button. Hold both buttons until the android repair image or the FASTBOOT label appears on the screen.
The software method is convenient if the buttons are damaged or the smartphone is far away. Through debugging via USB, type a command in the PC command line:
adb reboot bootloaderMake sure that the Windows Device Manager in the Android Devices or Android Bootloader Interface section does not have exclamation signs indicating driver problems.
β οΈ Warning: Don't confuse Fastboot mode with Recovery mode. Fastboot usually shows a hare fixing an android, or text on the screen. FASTBOOT, a in Recovery - a menu with a black background and logo TWRP or Mi-Recovery.
The process of installing TWRP through the command line
Now that the device is connected and in Fastboot mode, you can start directly recording the image. Open the command prompt (CMD) or PowerShell in the ADB tool folder. To check the connection, type in the command fastboot devices. If the device serial number is displayed in response, the connection is established correctly.
The main installation command is as follows:
fastboot flash recovery twrp_image_name.imgReplace. twrp_image_name.img You can use the real name of the downloaded file, and after you complete the command, you will see a message of success (Finished successfully), but at this stage you can not just restart the smartphone in the usual way, otherwise the regular Xiaomi recap will overwrite the device. TWRP backwards.
Immediately after the firmware is installed, you need to perform a special button combination to enter the newly installed Recovery. Press the Volume Up + Power buttons and hold them until the TWRP logo appears. If you release the buttons too soon or too late, the device can boot into the regular MIUI system.
βοΈ Firmware checklist TWRP
First steps after installation and protection against overwriting
When you first log in to TWRP, you'll see a menu with Install, Wipe, Backup, and more. It's customized for touch control, but it can be delayed on some models. The first thing you'll do is ask you to confirm the modification, swipe your thumb over the Swipe to allow modifications slider, and this will prevent you from automatically replacing the TWRP with a stock receptacle on the first boot.
Next, clear the data sections, especially if you plan to install custom firmware or get Root rights. Go to the Wipe menu and select Advanced Wipe. Check the Dalvik/ART Cache, Cache and Data. System and Internal Storage sections until you need to touch them unless you want to clean the phone completely.
If you plan to use Magisk to gain superuser rights, now is the time to install it. ZIP-Magisk file to internal memory or connect the flash drive through OTG. On the menu. TWRP Select Install, find the archive and confirm the installation by swipe.
What if the TWRP crashed after the reboot?
Typical errors and compatibility table
Users often face compatibility issues during the modification process. Using a TWRP image designed for a different model or revision of the processor can result in a broken touchscreen (not being able to press buttons on the menu) or a "brick." Always check the XDA Developers forum or 4PDA profile branch for your particular model.
| Model of the device | Code name | Type of firmware | Features of TWRP |
|---|---|---|---|
| Xiaomi Redmi Note 9 Pro | curtana / joyeuse | Recovery / Fastboot | A patchy Bootloader is required |
| Xiaomi Mi 9T Pro | raphael | Recovery | Full support, working steadily |
| Xiaomi POCO X3 NFC | surya | Recovery | Possible problems with data encryption |
| Xiaomi Mi 11 Lite | renoir | Recovery | Requires Android 11/12 version |
One of the common mistakes is to try to flash TWRP without first unlocking the bootloader. This action is doomed to failure and will give an error FAILED (remote: device is locked).It is also worth remembering that on devices with MediaTek processors the procedure may be different and require the use of the utility SP Flash Tool instead of Fastboot.
β οΈ Note: On devices with Snapdragon processors 865 and newer (Android) 11+) The dynamic partition is often used. For such devices, the firmware command may differ: fastboot flash. recovery_a twrp.img and fastboot flash recovery_b twrp.img.
π‘
The main rule of modding is never to use files intended for other models, even if they are called the same.
Possible risks and precautions
Software modifications always carry risks. In addition to the loss of warranty, there is a possibility of software failures. Some banking applications and services (Google Pay, Mir Pay) may stop working on devices with an unlocked bootloader or established Root rights.
Besides, OTA-Xiaomi updates will stop coming automatically or they will lead to an error.You will have to manually stitch full firmware images through Fastboot, saving user data, or reinstall each time. TWRP post-refresh.
If you have bootloop issues, TWRP allows you to clean up a Data partition or restore a backup from a previously created backup. This is the main advantage of custom recovery over standard. Always have an up-to-date backup at hand before making any changes to the system.
π‘
Save screenshots or write down the device's IMEI before work begins. In rare cases, a failure may require recovery of this number through an engineering menu or special utilities.