Installing TWRP on Xiaomi Redmi Note 5: a complete guide with unlocking the bootloader

The Xiaomi Redmi Note 5 (codenamed whyred) is still a popular device among custom firmware enthusiasts, despite the release of new models. Installing TWRP Recovery is the first step to advanced features from root rights to custom ROM firmware. However, the process has nuances related to Xiaomi’s policy of blocking the bootloader and features of the Qualcomm Snapdragon 636 architecture.

In this article you will find the current installation instructions. TWRP 3.7.0+ Redmi Note 5 with changes in 2026, from unlocking the bootloader through the Mi Unlock Tool to firmware recovering through fastboot and bypassing common bugs (such as anti-rollback or orange state). TWRP compatible with the latter MIUI, How to avoid the β€œbrick” with incorrect actions.

1. Device Preparation: What to Do Before Installing TWRP

Before starting the procedure, it is critical to follow several steps to minimize risks. Redmi Note 5 has anti-rollback protection, so improper actions can lead to the inability to recover through official Xiaomi tools.

Check out the current version of MIUI and Android:

  • πŸ“± Go to Settings. β†’ The phone. β†’ Version. MIUI and write down the number (for example, MIUI 14.0.5).
  • πŸ€– In the same menu, find the Android version (must be at least 9.0 Pie for compatibility with the latest versions). TWRP).
  • πŸ” Find out the code name of the device: enter in the terminal (or through the device). ADB) Getprop ro.product.device command should return whyred.

If your firmware is older than MIUI 12, it is recommended to upgrade to the latest official version via Settings β†’ System Update.This will reduce the risk of conflicts with anti-rollback when installing custom Recovery.

⚠️ Attention: On devices with MIUI 13+ Android 11/12 You may need to roll back to Android. 10 work-in TWRP. Use the section FAQ, if your version is newer.

πŸ“Š What version? MIUI You are using the Redmi Note 5?
MIUI 12 or older
MIUI 13
MIUI 14
Custom firmware
I don't know.

2. Unlock the bootloader: bypassing the restrictions of Xiaomi

Xiaomi blocks the bootloader on all devices, including the Redmi Note 5. Without unlocking, TWRP installation is impossible.

  • πŸ”“ Linking your Mi Account to your device (required!).
  • πŸ•’ Expectations 7–14 days after binding (if the account is new or has not previously unlocked the device).
  • πŸ’» Install Mi Unlock Tool on Windows PC (not officially supported) macOS/Linux).
  • πŸ”Œ USB-Fastboot-enabled cable (preferably original or high-quality charging cable).

Step-by-step:

  1. Download Mi Unlock Tool (version no lower than 5.5.224.30).
  2. Turn on the phone Developer Mode: go to Settings β†’ About Phone and 7 times click on the MIUI version.
  3. Back to Settings β†’ Additionally. β†’ For developers and activate: πŸ”§ Debugging by USB πŸ”— Unlocking OEM (may require input PIN-code).

Mi Unlock Tool

Mi

⚠️ Note: If the Mi Unlock Tool shows a "Couldn't unlock" or "Device not supported" error, check if your account is linked to your device (c Settings). β†’ Mi Account β†’ Mi Cloud should display the device. SIM-A card of the operator blocking the unlock (e.g. some Chinese operators) MIUI (slide back to stable).

Download the Mi Unlock Tool for the latest version|Enable the developer mode|Activate debugging by USB unlock OEM|Link Mi Account to your device|Wait 7-14 days (if the account is new)-->

3.Selecting a TWRP version for Redmi Note 5 (whyred)

Not all TWRP builds work equally well with the Redmi Note 5.

  • πŸ“… Date of assembly: use versions no older 2023 years, for example, twrp-3.7.0_12-0-whyred).
  • πŸ”„ Anti-rollback support: check if the version is compatible with your current version MIUI (see the table below).
  • πŸ› οΈ Type of build: for Android 10/11 fit TWRP-A/B, Android 9 β€” classic.

Official and recommended assemblies:

TWRP versionSupport for MIUIAndroidFeaturesReference
3.7.0_12-0MIUI 12–149–11FBE support, encryption bug fixedOfficial website
3.6.2_11-0MIUI 10–129–10Stable, but without support for new partition formatsXDA-Developers
3.5.2_9-0MIUI 9–118–9Older, more likely to have problems with MIUI 12+TWRP archive

For Redmi Note 5 with Android 11 (MIUI 13+), it is recommended to use a modified build of TWRP-A/B from mauronofrio or wrzd, as the official versions may not work correctly with dynamic partitions (super.partition).

πŸ’‘

Before downloading TWRP, check the hash file (MD5) on the developer’s website to help avoid fake builds with malicious code.

4. Install TWRP via Fastboot: a step-by-step process

Once you unlock the bootloader and download the correct version of TWRP, you can start the firmware.

  • πŸ–₯️ PC with installation ADB and Fastboot (instructions for installation here).
  • πŸ”Œ Cable USB (preferably original).
  • πŸ“ File. TWRP in.img format (e.g, twrp-3.7.0_12-0-whyred.img).

Instructions:

  1. Move the twrp-*.img file to the ADB folder (e.g., C:\platform-tools\).
  2. Turn off your phone and press Power + Volume Down to log into Fastboot Mode.
  3. Connect your phone to your PC and check for device detection by command: fastboot devices must display the serial number of the device.
  4. Please. TWRP Temporary (for test) team: fastboot boot twrp-3.7.0_12-0-whyred.img The phone will reboot to TWRP. Check the performance (sensor, buttons).
  5. If everything works, please. TWRP Fastboot Flash Recovery twrp-3.7.0_12-0-whyred.img
  6. Reboot to Recavator Team: Fastboot Reboot Recovery

⚠️ Note: If after the firmware TWRP The phone is loaded into the stock recavator, so overwriting protection is turned on (recovery_ramdisk). In this case: Download disable_force_encrypt_treble.zip (Android 10+) or no_verity_opt_encrypt.zip (Android 9). Please. ZIP via Install TWRP before the first reboot.

What if TWRP doesn’t see internal memory?
If the internal memory (/data) is not mounted after installing the TWRP, the reason may be: 1. File-Based Encryption (FBE) encryption – you need to enter a password in TWRP (Monute β†’ Enable MTP menu). 2. Incompatibility with the MIUI version – try to roll back to the older firmware. 3. Damaged partitions – run fastboot user formatdata (remove all data!). For Android 10+, OrangeFox Recovery firmware can help instead of TWRP.

5. Common mistakes and their solutions

When installing TWRP on the Redmi Note 5, users often encounter typical problems, and here are a list of bugs and ways to fix them:

Mistake.Reason.Decision
Fastboot: FAILED (remote: 'Flashing is not allowed in Lock State')The bootloader is not unlockedRepeat the unlocking with the Mi Unlock Tool
Orange State (Orange Warning at Download)Unofficial Recovery installedPlease. disable_dm_verity_forceencrypt.zip into TWRP
TWRP asks for password but doesn’t accept itFBE encryption on Android 10+Use TWRP-A/B or format /data (Data Loss!)
The phone does not turn on after firmware (brick)Incompatibility with anti-rollbackFly the stock firmware through the Mi Flash Tool in EDL mode

If the phone loads into a stock recave after installing TWRP, Xiaomi overwrote it the first time it boots.

  • πŸ”§ After the firmware TWRP Reboot it immediately (fastboot reboot recovery).
  • πŸ“¦ Or, you can run Magisk or no_verity_opt_encrypt.zip before first loading.
  • πŸ”„ Turn off automatic update of the recovery in the settings MIUI.

πŸ’‘

If the phone doesn’t boot into the system after installing TWRP, never try to flash the stock recavator over the custom one through the Mi Flash Tool, which will lead to a hard brick. Instead, use the fastboot boot twrp.img command to temporarily boot and fix errors.

6. Additional settings after installing TWRP

Successful TWRP installation is only half the battle, and to avoid future problems, follow these steps:

  1. Create a backup (backup): πŸ“± V TWRP Choose Backup. πŸ”˜ Mark the sections: Boot, Data, System, Vendor. πŸ’Ύ Save a copy for SD-PC or card (do not store only on internal memory!).
  2. Turn off forced encryption: πŸ”§ Please. disable_force_encrypt_treble.zip (Android 10+). πŸ”„ Reboot to TWRP and execute Format Data β†’ Yes (erases all data!).

Install Magisk for root rights:

  • πŸ“± Download the latest version of Magisk from GitHub.
  • πŸ”§ Please. ZIP via Install TWRP.
  • πŸ”„ Reboot and check the root through the Magisk Manager app.

If you plan to flash custom ROMs (like LineageOS or Pixel Experience), first:

  • πŸ” Check compatibility. ROM with your anti-rollback version (indicated in the firmware name).
  • πŸ“¦ Download firmware for your model (for example, fw_whyred_miui_HMNote5HMNote5ProGlobal_V12.5.2.0).
  • πŸ”§ Use firmware before installing custom ROM, avoiding conflict.

πŸ’‘

For easy management of TWRP, install the Quick Reboot app from Google Play, which allows you to reboot to the Recovery with one tap without using a combination of buttons.

7. How to return stock Recovery (if necessary)

If you need to return the original recovery (for example, for warranty repairs or sale of the device), follow the instructions:

  1. Download stock firmware for Redmi Note 5 from the official Xiaomi website (link).
  2. Unclose the firmware file and find the recovery.img file inside the images folder.
  3. Reboot your phone in Fastboot Mode (Power + Volume Down).
  4. Run stock recaps with the command: fastboot flash recovery recovery.img
  5. Reboot the device to the system: fastboot reboot

To return the device to a completely drain state:

  • πŸ”§ Flush the full firmware through the Mi Flash Tool in Clean All mode.
  • πŸ”’ Block the bootloader with the command: fastboot oem lock ⚠️ Attention: Locking the bootloader erases all data and can lead to a brick if the device has custom firmware or modified partitions installed!

FAQ: Frequent questions about installing TWRP on Redmi Note 5

❓ Can we determine TWRP loader-free?
No. Xiaomi blocks write to recovery and boot sections on all devices, including the Redmi Note 5. Any attempts to circumvent this software (for example, through exploits) result in a soft brick or anti-rollback. The only official way is to unlock through the Mi Unlock Tool. Alternative methods (for example, through EDL) require an authorized Xiaomi account and specialized hardware.
❓ What version? TWRP choose MIUI 14 on Android 12?
For MIUI 14 (Android-based 12) It is recommended to use a modified assembly TWRP-A/B from mauronofrio or OrangeFox Recovery. TWRP 3.7.0 You may not work properly with dynamic partitions (super.partition: TWRP 3.7.0 Android 12 OrangeFox Recovery
❓ This package is for whyred devices; this is a <codename>"?
This error occurs when you are trying to ZIP-File (such as custom firmware or Magisk) intended for another device. Check: Codename of your device (whyred for Redmi Note 5). Compatibility ZIP-file with your anti-rollback version (indicated in the firmware name, for example, ARB Integrity of the downloaded file (compare hash) MD5 If you're making custom ROM, Make sure it supports your version of firmware. Update firmware through Xiaomi Firmware Updater if necessary.
❓ Why After Installation TWRP phone doesn't see SIM-map?
This problem is due to damage to the modem partition or firmware incompatibility: πŸ“Ά Switch stock firmware for your model through TWRP (file extension). πŸ”§ Perform a complete reset (Wipe) β†’ Format Data) and run a clean firmware. πŸ“‘ Check if Airplane Mode is enabled in the settings. If the problem persists, return to the stock firmware via the Mi Flash Tool.
❓ Can we determine TWRP on the Redmi Note 5 through ADB (fastbootless)?
Technically yes, but this method is unreliable and only works on some versions. MIUI. Instructions: Download twrp-installer-*.zip (not.img!).Reboot to stock recaveri (Power) + Volume Up. Select Apply update from ADB. On PC, run the command: adb sideload twrp-installer-3.7.0_12-0-whyred.zip However, this method often leads to the error "E:footer is wrong" due to signature verification.