Installation of custom recaveri TWRP on smartphones Xiaomi, Redmi or POCO โ The first step is to take full control of the device, and you can run unofficial firmware, back up NANDroid, get root rights, or even restore a brick machine, but it requires care. A mistake in unlocking a bootloader or firmware can turn a phone into a โbrickยป.
In this guide, we will analyze the current installation methods for 2026 TWRP, This includes bypassing new Xiaomi restrictions (e.g., linking a Mi Account to a bootloader), which are suitable for most models on Qualcomm Snapdragon and Mediatek chips, but with specific lines in mind, from the budget Redmi Note 12 to the flagship Xiaomi 14. If your model is older than 2019, check compatibility in the official repository. TWRP.
1. Device Preparation: What to Do Before Installing TWRP
Before proceeding to unlock the loader and firmware TWRP, Follow the mandatory steps. Missing any of them can lead to data loss or locking the device.
First, back up all the important data. The bootloader unlock process will reset the phone to factory settings by deleting photos, contacts, and apps. Use Mi Cloud, Google Drive, or physical copying on your PC.
- ๐ฑ Contacts (export to.vcf)
- ๐ธ Photo/video (check folders) DCIM and Pictures)
- ๐ Passwords (save export from Google Smart Lock or Mi Account)
- ๐ฎ Save games (use Helium or root backup if you already have root)
Second, check the firmware version. Some Xiaomi models require a specific version. MIUI For example, on the Redmi Note 10 Pro, you may need to roll back to the right location. MIUI 12.5 if the current version is newer. โ The phone. โ Version. MIUI.
Make a data backup|Check the version. MIUI|Charge the phone to 70%+|Install ADB-PC drivers|Download the official TWRP forecast-->
Also make sure that:
- ๐ Battery charge at least 70% (the process can take up to an hour).
- ๐ฅ๏ธ Drivers are installed on the PC ADB/Fastboot (You can download from the Android website).
- ๐ฑ In the settings of the phone included debugging USB (Settings โ The phone. โ Version. MIUI โ 7 times to tap according to the version โ return to Settings โ Additionally. โ For developers).
๐ก
If you have a model on a Mediatek chip (e.g. Redmi). 9A or POCO C31), extra download the utility SP Flash Tool โ Youโll need it for your firmware TWRP Download Mode.
2. Unlocking the bootloader on Xiaomi: official and unofficial ways
The bootloader on Xiaomi smartphones is blocked by default. its unlocking is a mandatory step before installation TWRP. The official method requires the Mi Account to be linked to the device, but since 2023 Xiaomi has tightened the rules: now on some models you need to wait up to 720 hours (30 days) after the binding.
Alternative methods (for example, through the XiaomiTool utility) V2) They can bypass the wait, but they're risky:
- Link your Mi Account: Go to Settings โ Xiaomi Account. Sign in or create a new account. Under Mi Unlock Status, click Add Account and Device.
Mi Unlock Tool
official website
Launch the utility.
Fastboot
Loudness down + Nutrition
Follow the instructions.
If you receive a notice of waiting, wait until the specified time (usually 168 or 720 hours).
I don't want to wait, I'm looking for a way around.|168 hours (7 days)|720 hours (30 days)|Already unlocked.-->
โ ๏ธ Note: If you use unofficial unlock methods (e.g., through the EDL Mode, consider:
โ ๏ธ On models with Snapdragon chip 8 Gen 2/3 (for example, Xiaomi 13T Pro or Redmi K60 Ultra) Unofficial unlocking may result in hardware locking IMEI. Recovering it later will be extremely difficult.
For models POCO F5, Redmi K50 Xiaomi has introduced an additional protection called Anti-Rollback, which means that once unlocked, you won't be able to flash the old version. MIUI or TWRP, I've been using it for an earlier firmware. XDA Developers.
3. Download the correct version TWRP for your model
Mistake in the choice of version TWRP โ One of the main reasons for the "bricking" of devices, even if the phone model is the same, the firmware may differ depending on the type of hardware that is used:
- ๐ฑ Regional code (e.g. Redmi Note 11 Pro) 5G For India, viva, for the global market, veux).
- ๐ง Chipset versions (e.g., Snapdragon) 732G vs Mediatek Helio G95 single-line).
- ๐ก Like a memory (UFS 2.1 vs UFS 3.1 - affects the marking of sections).
Where to download the relevant TWRP:
- Type the model name in the search (for example, Redmi Note 12 Pro)+).
- Forum XDA โ They often publish informal builds that support new devices. [UNOFFICIAL].
- Developer Telegram channels (e.g, @twrp_updates).
Before downloading, check:
- ๐ Device code name (you can find out in Settings) โ The phone. โ Model or via adb shell getprop ro.product.device).
- ๐ Assembly date TWRP (If the firmware is older than 6 months, look for a newer firmware).
- ๐ Support A/B-partitions (relevant to Dynamic Partition devices, for example, POCO F4 GT).
How to find out the code name of the device if the phone is not turned on?
| Xiaomi model | Code name | Type of chipset | Features of TWRP |
|---|---|---|---|
| Xiaomi 13 Pro | nuwa | Snapdragon 8 Gen 2 | Requires a shutdown. avb2.0 into vendor_boot |
| Redmi Note 12 Pro+ 5G | ruby | Mediatek Dimensity 1080 | Support A/B (Seamless) updates |
| POCO F5 | marble | Snapdragon 7+ Gen 2 | We need to patch. boot.img Magisk |
| Redmi 10C | fog | Snapdragon 680 | Only unofficial assembly (no official assembly) TWRP) |
4. Install TWRP via Fastboot: step-by-step instruction
When the bootloader is unlocked and the correct version is unlocked TWRP We'll look at a generic method through Fastboot, which works on 90% of Xiaomi devices.
What you need:
- ๐ฅ๏ธ PC with installation ADB/Fastboot (Check the work of the team fastboot devices).
- ๐ฑ Phone with unlocked bootloader and enabled debugging USB.
- ๐ File. TWRP in.img format (e.g, twrp-3.7.0_12-veux.img).
Instructions:
- Transfer the phone to Fastboot: adb reboot bootloader Or manually: turn off the phone, press Volume down + 10 seconds power.
- Check the connection: fastboot devices must display the serial number of the device.
- Please. TWRP: fastboot flash recovery twrp-3.7.0_12-veux.img (Replace the file name with yours).
- Stop Recovery Replacement (Important!): Fastboot Flash recovery_ab twrp-3.7.0_12-veux.img (for devices A/B-partition).
- TWRP: Fastboot Reboot Recovery
โ ๏ธ Note: On some models (e.g. Xiaomi) 12T or Redmi K50 Gaming) after firmware TWRP The system can automatically restore the stock Recovery:
โ ๏ธ Immediately after the first loading in TWRP Go to Advanced. โ Flash Current TWRP (If there is such a point, or file disable_forced_encryption.zip (download XDA).
๐ก
If after the reboot the phone is stuck on the logo MIUI, signifier, TWRP Repeat the firmware by disabling the signature check with fastboot flash vbmeta vbmeta.img (file vbmeta.img can be extracted from the stock firmware).
5. Alternative methods of installing TWRP
If the standard Fastboot method didnโt work, try alternatives that are relevant for devices with a locked bootloader (but not all models!) or for problems with a Fastboot.
Method 1: Firmware through SP Flash Tool (for Mediatek)
Suitable for Mediatek chip-based devices (e.g. Redmi) 9A, POCO C31). It will:
- ๐ Stock firmware in.zip format (download from Xiaomi website).
- ๐ ๏ธ Utility. SP Flash Tool (version 5.2 or later).
- ๐ง scatter.txt file from the firmware archive.
Instructions:
- Unpack the stock firmware and replace the file recovery.img yours TWRP.img.
- Open up. SP Flash Tool, download scatter.txt.
- In the file list, leave a checkmark just opposite recovery.
- Connect the phone to the PC (no buttons!).
- Click Download and wait until the end (the green circle will appear).
Method 2: Installation via OrangeFox (for new devices)
OrangeFox Recovery is an alternative TWRP, It works better with new Xiaomi models (such as Xiaomi 13 or Redmi Note 12 Turbo:
- ๐ง Support for Dynamic Partition and A/B-update.
- ๐ Built-in protection against replacement of stock Recovery.
- ๐ฑ More modern interface with touch control.
It is set similarly. TWRP, But the file must be downloaded from the official website.
Method 3: Through ADB Sideload (if the phone is switched on)
If the phone is loading, but you want to install it TWRP fastbootless:
- Download the TWRP file in.zip (not.img!) format.
- Go to Settings โ About Phone โ System Update โ Three Dots โ Select a firmware file.
- Select the downloaded.zip and wait for the installation.
What to do if after installation TWRP If you've used encryption in your phone MIUI, TWRP request a password to decrypt the section /data. If you don't remember him
6.The first steps of TWRP: what to do after installation
After successful loading into TWRP Take some critical steps to avoid future problems:
1. Create a backup (Nandroid Backup)
- Go to the Backup section.
- Select the sections: Boot, System, Data, Vendor.
- Click Swipe to Backup and wait until it is completed.
- Copy the TWRP/BACKUPS folder to your PC or cloud.
2. disable forced encryption (if necessary)
New Xiaomi devices have encryption enabled /data, jeopardy TWRP. To turn it off:
- Download. disable_dm-verity_forceencrypt.zip (link).
- V TWRP press Install โ select the file โ Swipe to Confirm Flash.
- Reboot to the system.
3. Install Magisk for root rights (optional)
If you need root rights:
- Download the latest version of Magisk from GitHub.
- V TWRP file Magisk-v26.4.zip (version may differ).
- Restart and check for root through the Magisk Manager app.
๐ก
If after installing Magisk phone is fixated on the boot, sew through TWRP file boot.img, Prepatched Magisk (instruction: fastboot flash boot) magisk_patched.img).
โ ๏ธ Note: On devices with Dynamic Partition (e.g. Xiaomi) 12 or POCO F4) For the correct operation of Magisk you need to stitch boot.img, init_boot.img:
โ ๏ธ Use the command: fastboot flash init_boot magisk_patched.img Otherwise, the root will not work, and the system may not boot.
7. Common mistakes and their solutions
Even with the correct following of the instructions, there can be problems, and let's look at the most common errors and how to correct them.
| Mistake. | Reason. | Decision |
|---|---|---|
| Fastboot: unknown command | No ADB/Fastboot drivers installed | Install Platform Tools or reinstall drivers via Mi Flash Tool |
| Phone is not defined in fastboot devices | Incorrect mode or drivers | Check the connection (port) USB 2.0), reinstall drivers manually through Device Manager |
| Invalid sparse file format at header | A TWRP file or incompatible version is damaged | Download another file. TWRP Check the code name of the device. |
| After firmware TWRP phone loads into stock recavator | MIUI re-creating | Please. recovery_ab Turn off the check with fastboot flash vbmeta vbmeta.img |
| This package is for "Xiaomi;veux" devices; this is a "Xiaomi;ruby". | Codename mismatch | Download. TWRP For the correct model (in this case, for ruby, not veux) |
Error: "Device is locked. Cannot flash"
If you see this message in Fastboot, it means the bootloader is not unlocked.
- Check the unlock status of the command: fastboot oem device-info Look for the lines Device unlocked: true.
- If false, repeat the unlock process through the Mi Unlock Tool.
- Use 720 hours to bypass the waiting time EDL Mode (for experienced users only!).
Mistake: TWRP asks for a password, but it's not there.
It's because of encryption. /data. Options for a solution:
- Reset data (loss of all files!): TWRP: Wipe โ Format Data โ enter".
Disable encryption
- Please. disable_dm-verity_forceencrypt.zip.
- Or disable encryption in the settings MIUI before installation TWRP.
How to update MIUI s TWRP:
Update MIUI through OTA manually:
- ๐ Don't update through the standard menu! Download the full firmware package (.zip) from the official website.
- ๐ V TWRP before-fixing MIUI Turn off signature verification: Settings โ Enable Zip signature verification: OFF
- ๐ง After updating MIUI re-sweeve TWRP, The system can replace it.