How to completely disable root rights on Android Xiaomi: 5 proven ways

Getting root rights to Xiaomi opens up access to hidden system functions, but often leads to problems ranging from the failure of banking applications to the loss of warranty. If you decide to return the smartphone to its original state - for example, to sell, update firmware or restore Google Pay - it is important to properly disable root rights to avoid soft breeze or download errors.

In this article, we will discuss all the current root removal methods on Xiaomi, Redmi and POCO devices (including the 2023-2026 models on MIUI 14/15 and HyperOS).

  • ๐Ÿ”„ Remove root through Magisk (the safest method)
  • ๐Ÿ“ฑ Return stock recovery if you have installed TWRP
  • ๐Ÿ”ง Reset the Orange State counter (to unlock the bootloader)
  • ๐Ÿ› ๏ธ Restore the guarantee after the rollback of superuser rights

Before you start, check which root type you have activated. Go to the Magisk app (if installed) or run a command in the terminal:

su

If the terminal is sending out a # instead of $, the root is active. If the command is not recognized, the permissions have already been disabled or deleted incorrectly.

๐Ÿ“Š Why you should remove root on Xiaomi?
I want to sell my phone.
We need to update the firmware.
Applications have stopped working
Reinstatement of the guarantee
Other

If you get root with Magisk (the most popular method for Xiaomi), the rollback will take no more than 5 minutes, which is suitable for most devices, including the Xiaomi 13/14, Redmi Note 12 and POCO F5.

Note: Before deleting, back up your data via MIUI Backup or Titanium Backup. Deleting Magisk doesn't affect user files, but resetting to factory settings (if necessary) erases everything.

  1. Open the Magisk app (if not, download the latest version from the official GitHub).
  2. Go to the Settings section (โš™๏ธ) โ†’ Delete Magisk (Uninstall).
  3. Select Complete Uninstall and confirm the action.
  4. After the reboot, check the root status with the su command in the terminal - must return the error.

If the phone does not boot or freezes on the MI logo after removing Magisk, the system files have been changed, in which case you will need to flash the stock firmware (see section 4).

โ˜‘๏ธ Preparing for the removal of Magisk

Done: 0 / 4

2. rollback via TWRP (if custom recovery is installed)

If you installed root through TWRP, simply removing Magisk might not work, and you'll still have traces of modifications in the system, so you'll need to return the stock recovery and flash the original boot.img.

Critical! For Xiaomi devices with a locked bootloader (for example, after an official update), firmware through fastboot can lead to a hard brick.

fastboot oem device-info

If the answer Device unlocked: false โ€“ the bootloader is blocked, and you can not flash boot.img through fastboot!

โš ๏ธ Note: Some models (e.g. Xiaomi) 12T or Redmi K50) flash-stitch boot.img This will trigger the anti-rollback โ€“ the phone will need a full flashing through the phone. EDL.

Instructions for devices with unlocked loader:

  1. Download stock firmware for your model from MIUI Downloads website.
  2. Remove the boot.img file from the archive (for HyperOS, look in the image folder).
  3. Reboot your phone to TWRP (hold Power + Volume up).
  4. In TWRP, select Install โ†’ Install Image and swipe the boot.img download to the Boot section.
  5. Reboot to the system and check root with the su command.
What if TWRP doesnโ€™t see internal memory?
If TWRP doesnโ€™t display files in internal memory, connect your phone to your PC via USB and copy boot.img to a flash drive. Then in TWRP, select Mount โ†’ Enable MTP and repeat the firmware.

3. Reset the Orange State counter (to unlock the bootloader)

After removing the root, the Orange State warning may remain on the download screen, meaning that the bootloader is unlocked and the manufacturer (in this case, Xiaomi) considers the device to be modified. To remove this message and return the possibility of official updates, you need to:

  1. Put your phone in fastboot mode (keep Power + Volume down when turned on).
  2. Connect the device to the PC and execute the command:
fastboot flashing lock

This command will lock the bootloader, but erase all the data on the phone! Once executed, the device will automatically restart.

If the command fails (it produces a FAILED error), the device has activated anti-rollback protection.

  • ๐Ÿ”น Download the latest stock firmware for your model.
  • ๐Ÿ”น Fly it through the Mi Flash Tool with the clean all and lock option.
  • ๐Ÿ”น Wait 72 hours โ€“ Xiaomi may temporarily block unlock after frequent change in bootloader status.

๐Ÿ’ก

If the phone doesnโ€™t turn on after locking the bootloader, try flashing the firmware through EDL mode using the QFil tool or Mi Flash Pro (an authorized Xiaomi account is required).

4. Complete flashing through the Mi Flash Tool (radical method)

If previous methods have not worked (for example, after unsuccessful experiments with custom firmware), the only reliable option is to flash stock firmware through fastboot. This method is suitable for all Xiaomi models, including the POCO X5, Redmi Note 11 and older devices.

You will need to:

  • ๐Ÿ–ฅ๏ธ Windows computer (for Mi Flash Tool).
  • ๐Ÿ”Œ Cable USB (preferably original).
  • ๐Ÿ“ฆ Stock firmware in.tgz or.zip format (download only from the official website).

Step-by-step:

  1. Unpack the firmware archive in a folder without Cyrillic characters (for example, C:\MIUI\).
  2. Install the Mi Flash Tool and Xiaomi drivers.
  3. Transfer the phone to fastboot mode and connect to the PC.
  4. In the Mi Flash Tool, click Select and specify the path to the firmware folder.
  5. Select the clean all mode (erase data) or clean all and lock mode (erase data and block the bootloader).
  6. Press Flash and wait until it is completed (usually 5-10 minutes).
Firmware modeWhat's he doing?When to use
clean allDeletes all data, flashes the systemIf you just need to return the stock firmware
clean all and lockDeletes data + blocks the loaderTo restore warranty or remove Orange State
save user dataSwitching the system without deleting filesOnly if you are sure that the modifications did not affect /data

โš ๏ธ Note: Firmware via the Mi Flash Tool on HyperOS devices (e.g. Xiaomi 14) may require authorization of your Xiaomi account. If the tool gives you a flash authorization failed error, link the device to your account in the Mi Unlock Status settings.

5. Verification of success of root removal

After you do any of these things, you need to make sure that the root rights are actually disabled.

  1. Check through the terminal: Open the Terminal app (or ADB Shell) and type in:
su

If a message appears Permission denied or command not found, root is deleted.

  1. App Check: Install Root Checker from Google Play. If the app shows Root access: Not available, it's okay.
  2. SafetyNet Check: Run at the terminal:
su -c "getprop ro.boot.verifiedbootstate"

If the answer is orange, the bootloader is unlocked, green is blocked.

Also check the critical applications:

  • ๐Ÿ’ณ Google Pay, SberPay โ€“ should be launched without errors.
  • ๐Ÿฆ Banking applications (SberBank, Tinkoff) โ€“ do not issue warnings about the rut.
  • ๐ŸŽฎ Protected games (e.g., games, Pokรฉmon GO) โ€” work without restrictions.

๐Ÿ’ก

If the banking apps still don't work after you remove root, clear the Google Play Services data and restart the phone, sometimes taking up to 24 hours to reset the SafetyNet flag.

6. Restoration of warranty after root removal

Even after the root is completely removed, the manufacturer may refuse warranty repairs if:

  • ๐Ÿ”ง The service menu (#4636##) has traces of modifications.
  • ๐Ÿ“ฑ bootloader unlocked (checked through fastboot oem device-info).
  • ๐Ÿ”„ There is an unofficial firmware installed on the device.

To maximize the chances of warranty service:

  1. Swipe stock firmware through the Mi Flash Tool with the clean all and lock option.
  2. Reset the counters of modifications (if any) through fastboot:
fastboot erase avb_custom_key


fastboot erase userdata

  1. Do not update the firmware manually โ€“ wait OTA-updates through settings.
  2. Before visiting the service center, reset to factory settings (Settings โ†’ About phone โ†’ Reset settings).

If the service center refuses to accept the device under warranty, request an official opinion on the reason for the refusal. In some cases, it helps to contact Xiaomi with evidence of a return to stock firmware (screenshots of fastboot and Mi Flash Tool).

FAQ: Frequent questions about removing root on Xiaomi

Can root be deleted without data loss?
Yes, if you use the Magisk deletion method (Section 1). However, when you run through the Mi Flash Tool or reset the bootloader, all data will be erased. We recommend you pre-backup using MIUI Backup or Titanium Backup (if it works without root).
Once root is removed, the phone doesn't turn on. What do I do?
There was probably a boot.img firmware bug or modification conflict. Try: Swipe stock firmware through fastboot (section 4). If the phone is not detected in fastboot, turn it into EDL mode (keep Power + Volume up + Volume down 10 seconds) and swipe through Mi Flash Pro. If nothing helps, contact the service center - the memory markup may be damaged.
How do I know if my Xiaomi bootloader is unlocked?
There are three ways: When you boot your phone, if you say Orange State, the bootloader is unlocked. Through fastboot: fastboot oem device-info, look for the lines Device unlocked: true. In settings: Settings โ†’ About Phone โ†’ MIUI Version (click 7 times) โ†’ Additional โ†’ Uploader Status.
Will it work? OTA-Update after root removal?
Yes, but only if: ๐Ÿ”น You have returned stock recovery (removed) TWRP). ๐Ÿ”น The boot loader is locked (fastboot flashing lock). ๐Ÿ”น System files have not been changed (for example, applications have been deleted). MIUI). If the update does not come, check the status of Xiaomi servers or manually download the firmware from the official website.
Can I get root again after removal?
Yeah, but keep it in mind: ๐Ÿ”น On new devices (for example, Xiaomi 13 Ultra or other devices). POCO F5 Pro) unlocking the bootloader takes up to 7 days of waiting. ๐Ÿ”น Re-unblocking resets all data. ๐Ÿ”น On some models (for example, Redmi Note 12 Pro)+) after unlocking can trigger anti-rollback, blocking the rollback to old firmware.