Backup through TWRP โ critical step before any manipulation of the firmware Xiaomi, whether it is the installation of custom software, unlock the bootloader or even a banal update through fastboot. Error in the selection of partitions for backup can lead to loss of personal data, disruption of the module NFC, Or even the device's "brick" when the smartphone turns into a useless "brick," but how do you know which sections are really important and which ones you can skip to save space on the memory card?
In this article, we will analyze not only the standard set of sections (boot, system, data), but also those that are often forgotten: persist (responsible for the maintenance of the system). IMEI and the serial numbers of the modules, modem (contains the modem firmware), and even a vendor, without which the cameras on some Redmi models can stop working. POCO. We will pay special attention to the โpitfallsโ of the backup on devices with dynamic partitions, which Xiaomi has been actively implementing since 2021.
You will learn how to name backups correctly, so as not to get confused in them after six months, why you can not backup the userdata section on devices with encryption FBE (File-Based Encryption) without prior preparation, and how to restore only individual partitions if something goes wrong. And for owners of flagships like Xiaomi 13 Ultra or Mix Fold 3, we have prepared separate recommendations โ these models have unique sections that you will not find in the budget Redmi.
Why backup in TWRP Xiaomi is not a luxury, but a necessity.
Many Xiaomi users mistakenly believe that backup is only needed before installing custom firmware like LineageOS or Pixel Experience. MIUI Updaters may not go according to plan, especially if youโre switching between Android versions (like 12 to 13:
- ๐ฑ Lose all data in Internal Storage, including photos and videos (even if they were in the cloud, the application cache cannot be restored).
- ๐ก Staying out of touch due to a damaged modem partition โ SIM cards will simply cease to be defined.
- ๐ Get the error "Device is corrupted" when downloading if the boot or dtbo is damaged.
- ๐ฎ Lose the performance of sensors (gyroscope, accelerometer) due to a failure in persist.
Moreover, since 2022, Xiaomi has been actively using dynamic partitions in its devices, which means that traditional partitions like the system or vendor can be replaced with a super โ a single container that is designed to be used for the purpose of creating a new system. TWRP Without special plugins or manual subdivision of super, your backup will be useless.
โ ๏ธ Attention: On devices with Android 12+ Dynamic partitions (e.g. Xiaomi 12 Pro, Redmi Note 11 Pro)+) standard backup TWRP It doesn't save critical data from super, and it requires modified versions of recovery or scripts like lpunpack.
Another common error is the backup of the userdata partition on File-Based Encryption devices (FBE). If you didnโt turn off the encryption before creating a backup, it wonโt be possible to restore it โ TWRP It just can't decrypt the data. This applies to all Xiaomi on Android 10.+.
List of mandatory sections for backup in TWRP Xiaomi
Not all partitions are equally useful, for example, backup cache or recovery is mostly useless, and you can restore them automatically, but persistent or modem can be a serious problem. Below is the minimum set of partitions you need to backup on any Xiaomi device (including Redmi and the like). POCO):
| Section | What it keeps. | Effects of loss | Mandatory? |
|---|---|---|---|
| boot | kernel and ramdisk (boot settings) | The device will not boot or will be bootloop | โ Yes. |
| dtbo | Device configurations (DTBO โ Device Tree Blob Overlay) | Sensors, cameras, speakers are not working. | โ Yes. |
| modem | Modem firmware (basebands, IMEI) | No network, no definition. SIM-map | โ Yes. |
| persist | IMEI, Module serial numbers, sensor calibration | Loss of loss IMEI, The camera/gyroscope is not working | โ Yes. |
| vendor | Proprietary drivers and libraries | Cameras are not working, Wi-Fi, Bluetooth | โ Yes. |
For devices without dynamic partitions (up to Android 11), it is also recommended to backup:
- ๐ system - the firmware itself (useful if you want to roll back on the previous version).
- ๐ฑ Data โ User data (only if encryption is disabled) FBE!).
On devices with dynamic partitions (Android 12)+) Instead of system and vendor, it's going to be a super section:
- Use it. TWRP Support for Dynamic Partitions (e.g., OrangeFox or SkyHawk versions).
- Or manually unpack super into subsections using lpunpack.
Charge the device to a minimum 50%|Download the current version TWRP forecast|Disable encryption (if you plan to backup data)|Check the vacant space for SD-card (backup takes up) 3-10 GB)|Take a screenshot of the current version MIUI (Settings โ The phone)
-->
How to Backup Partitions with Dynamic Partitions (Super)
If your Xiaomi device is running on Android 12/13/14, It probably has a super section instead of the traditional system, vendor and product. TWRP can not properly backup such a section, so you will have to use workarounds.
Here are three working ways:
- Use modified recovery: ๐ ๏ธ Install OrangeFox Recovery or SkyHawk TWRP โ They support dynamic partitions out of the box". ๐ In the backup menu, select Super (Dynamic) โ recovery will automatically unpack it into subsections.
super
adb pull /dev/block/by-name/super super.img
lpunpack super.imgThis will create a folder with sections. system.img, vendor.img etc. which can be separately used.
Backup via Fastboot
fastboot flash backup_super super.img
fastboot rebootThen copy it. backup_super PC-only.
For Xiaomi devices with HyperOS (new Android 14 software), the process is complicated โ some modified recovery does not yet support new partition structures, in which case the only reliable way is to back up through fastboot or use the new partition structures. MIUI Official Recovery with backup (but it doesnโt save all partitions).
โ ๏ธ Attention: On Xiaomi 13T Pro, Redmi K60 Ultra and other devices with UFS 4.0 The backup of the super section can take up to 20-30 Do not interrupt the process, even if recovery seems to be โhangingโ โ this is normal for high-speed memory.
What to do if TWRP I can't see the super section?
What sections can not be backup (and why)
Some of the sections are not all equally useful. Some of them take up a lot of space, but you can restore them automatically or they don't contain critical information. Here's a list of partitions that you can skip without risking to the device:
- ๐๏ธ cache - application cache and temporary files, restored automatically when you first download.
- ๐ Recovery is the recovery itself. If it's damaged, you can always reflash it over fastboot.
- ๐ฆ metadata โ service data for F2FS (File system. You can restore it via fastboot. format:f2fs /dev/block/....
- ๐ง misc - system status flags (e.g. reset counter) - not critical for operation.
- ๐ก Bluetooth is a Bluetooth firmware module that is restored from the vendor or official firmware.
You can also skip:
- ๐ต dsp is the audio processor settings. It only affects the sound in the headphones, it's recovered from the stock firmware.
- ๐ก Wifi is the firmware of the Wi-Fi module. Like Bluetooth, it's not critical.
However, there are two exceptions when even "unnecessary" sections are worth saving:
- If you are experimenting with custom cores (such as FrancoKernel or Kirisakura), the boot and dtbo backup should include all related partitions, including vbmeta (responsible for checking the integrity of the boot).
- On certain devices (e.g, POCO F5 or Redmi Note 12 Pro+) The metadata section contains data from Virtual A/B โ The loss of the system can lead to a cyclical reboot.
๐ก
If you're not sure if a specific section backup is needed, check its size. 10 MBs (e.g. misc, keymaster) are usually not critical (100-300 MB) or persist (5-20 MB - mandatory.
Step-by-step: how to make a backup in TWRP Xiaomi
Now, let's get to the practice. Here's a step-by-step algorithm for backing up the data. TWRP For any Xiaomi device:
- Preparation of the device: ๐ Charge your smartphone at least 50% (better 80%). ๐ Move important files from internal memory to your PC or cloud (data backup is not always reliable). ๐ Turn off encryption (if you plan to backup data): go to Settings โ Additionally. โ Confidentiality โ Encryption and Accounts and Delete PIN/password.
- Loading into TWRP: ๐ Turn off the device. ๐ Hold the Power. + Volume Up before the logo appears MI (Some models need to be kept in place. 10-15 seconds). ๐ฑ If you have a request to unlock the bootloader, confirm (this is normal for first launches). TWRP).
- Creating a backup: ๐ Go to the Backup section. โ Check the sections from our list (see table above). ๐พ Select a location to save (preferably MicroSD or USB-OTG, Because internal memory can be encrypted). ๐ Press Swipe to Backup and wait until it is completed (can take 5 to 30 minutes).
Backup check.
- ๐ Go to the folder. TWRP/BACKUPS/[Serial number and make sure that the files are not damaged.
- ๐ Check the size of the archives: boot is usually 30-100 MB, data - several GB.
๐ก
Do not rename backup files manually! TWRP It uses a strict name structure (for example, 2026-05-20--12-34-56_boot_emmc.img). Changing the name will lead to errors in the recovery process.
Frequent errors in backup TWRP and how to avoid them
Even experienced users sometimes have problems building backups.-5 errors and ways of solving them:
| Mistake. | Reason. | Decision |
|---|---|---|
| "Unable to mount /data" | Encryption is on. FBE, TWRP Can't decipher the section | Turn it off. PIN/password MIUI before loading into recovery |
| "Backup failed: insufficient storage" | There is not enough space on the memory card. | Use it. SD-map โฅ32 GB or USB-OTG |
| "E:unknown filesystem 'f2fs'" | TWRP It does not support the file system F2FS | Install a newer version of recovery with support F2FS |
| Backup has been built for too long (>1 hour) | Memory problems (UFS/EMMC) cable OTG | Check the cable, try another port. USB |
| After recovery, there is no network (IMEI reset) | No backup was provided to the persist or modem partition. | Restore these sections separately or run the stock modem through fastboot. |
Another common problem is damaged backups, to avoid this:
- ๐ Do not remove the memory card during the backup.
- ๐ Do not allow the battery to be below 20%.
- ๐ต Do not interrupt the process (even if recovery seems to be stalled").
If the backup is still damaged, try to restore it through ADB:
adb pull /sdcard/TWRP/BACKUPS/ [path to PC]
tar -xvf [backup name].tarCheck the integrity of the files using sha256sum.
โ ๏ธ Note: On HyperOS devices (e.g. Xiaomi 14 or Redmi) K70) Standard backup methods may not work due to the changed super structure. In this case, use the official Mi Flash Tool to create a full copy of the firmware.