Smartphones Xiaomi based MIUI are known for their functionality, but over time, even 128 GB of memory can become clogged with unnecessary files. System folders, application caches, update remnants - all this takes up precious space, slows down the device and drains the battery. However, not all folders can be emptied without risk. An error when deleting system files can lead to MIUI crashdata loss or even a device brick.
In this article we will look at which folders on Xiaomi can be safely cleanedwhich ones are strictly not recommended to be touched. We will analyze the structure of the file system MIUI 14/15, look at hidden directories that are often overlooked, and provide step-by-step guide for beginners and experienced users. We will pay special attention folders that MIUI creates automatically, but never cleans itself โthey are the ones that most often become the source of problems.
Before you start cleaning, remember: not all folders are equally useful. What seems like garbage may be critical for the operation of the camera, instant messengers or system services. Therefore, each section of the article contains not only a list of folders, but detailed explanationswhy they can (or cannot) be deleted.
1. Application cache folders: what can be deleted without consequences
Application caches are temporary files that are created to speed up apps. Over time, they accumulate and can take up several gigabytes. On Xiaomi the cache is stored in two main places:
- ๐
/data/data/<package_name>/cache/โ application-specific cache (requires root access to access) - ๐๏ธ
/Android/data/<package_name>/cache/โ external cache (accessible without root) - ๐
/storage/emulated/0/Android/obb/โ additional game files (can be deleted manually)
You can safely clear the cache through MIUI settings:
- Open
Settings โ Applications โ Manage applications. - Select the desired application (for example, YouTube or TikTok).
- Click
Storage โ Clear cache.
For bulk cleaning, use the built-in utility Cleaning (broom icon in the settings menu). It automatically finds unnecessary cache, thumbnail and temporary files. data. However, the utility does not always delete deep cache โthis will require manual cleaning through the file manager (for example, Mi File Manager or Solid Explorer).
โ ๏ธ Attention: Do not confuse the cache with application data! Clearing the partitionData(notCache) will lead to resetting the app settings and logging out of your account.
2. MIUI system folders: what can be touched and what not
The file system MIUI contains dozens of hidden folders, many of which are critical for the operation of the system. Below is a table with directories allowed and prohibited for cleaning:
| Folder | Path | Can I clean? | Notes |
|---|---|---|---|
DCIM/.thumbnails |
/storage/emulated/0/DCIM/.thumbnails |
โ Yes | Thumbnails of photos and videos. They are deleted without consequences. |
MIUI/Backup |
/storage/emulated/0/MIUI/Backup |
โ Yes* | MIUI backups. You can delete if you do not use backups. |
MIUI/Extra |
/storage/emulated/0/MIUI/Extra |
โ No | Contains theme and system font files. |
lost.dir |
/storage/emulated/0/lost.dir |
โ Yes | Recovered files after failures. Usually empty or damaged. |
Android/obb |
/storage/emulated/0/Android/obb |
โ Yes** | Additional game files. Delete if the game is deleted. |
* - If you use the function Local backup in Settings โ About phone โ Backup copying, do not delete the folder Backup.
** - Some games (for example, Genshin Impact or Call of Duty Mobile) store critical files in obb . Delete only after uninstalling the game.
The folder /MIUI/Extradeserves special attention. It contains:
- ๐จ Custom themes (
.mtzfiles) - ๐ค System fonts
- ๐ฑ Animation and icon files
Its cleaning will lead to resetting the themes to standard ones and may cause errors in the interface.
Before clearing system folders, create a backup copy via Settings โ About phone โ Backup โ Local backup. This will take 5-10 minutes, but will save data in case of an error.
3. Folders with MIUI updates: how to free up gigabytes
One โโof the main "eaters" of memory on Xiaomi is update files. Even after installing a new version of MIUI, the system does not always remove old packages. They can take up from 1 to 3 GB and are stored in the following folders:
- ๐ฆ
/cache/โ temporary update files (root required for cleaning) - ๐
/data/ota_package/โdownloaded OTA packages (over-the-air updates) - ๐๏ธ
/storage/emulated/0/Downloaded_ROM/โ manual firmware downloaded via Software update
To clear them:
- Open
Settings โ About phone โ MIUI update. - Click on the three dots in the upper right corner and select
Delete downloaded package. - For folder
Downloaded_ROMuse the file manager and delete files with the extension.zip.
If you have root-access, you can clear /cache/ via TWRP or the command:
su
rm -rf /cache/*
โ ๏ธ Attention: Do not delete files from /data/ota_package/ manually if you are not sure of their purpose. Some packages may be needed to roll back to a previous version of MIUI.
What should you do if, after cleaning updates, your phone no longer sees new versions of MIUI?
If you deleted files from /data/ota_package/ and the system stopped offering updates, do the following steps:
1. Reboot your phone.
2. Open Settings โ About phone โ MIUI update and press Check for updates 2-3 times in a row.
3. If that doesn't help, reset your network settings in Settings โ SIM cards and mobile networks โ Reset network settings.
4. Messenger folders: how to clean Telegram, WhatsApp and Viber
Messengers are leaders in creating unnecessary files. Only Telegram can take up to 5-10 GB cache of media files, stickers and voice messages. Main folders:
| Messenger | Folder | What it stores | How to clear |
|---|---|---|---|
| Telegram | /storage/emulated/0/Telegram/Telegram Images/ |
Photos and pictures from chats | Delete manually or via Telegram Settings โ Data and memory โ Storage |
/storage/emulated/0/WhatsApp/Media/ |
Photos, videos, voice | Via WhatsApp Settings โ Memory or file manager |
|
| Viber | /storage/emulated/0/Viber/media/ |
Media files and stickers | There is no cleaning in Viber settings - only manual |
For Telegram there is a hidden cleaning function cache:
- Open Telegram and go to
Settings โ Data and memory. - Select
Storageand sort files by size. - Click
Clear cacheor delete unnecessary files manually.
You can configure automatic deletion media: WhatsApp You can configure automatic media removal:
- Go to
Settings โ Memory. - Select
Memory managementand mark files to delete. - Activate the option
Automatic deletionfor media older than 30/90 days.
โ ๏ธ Attention: In folder WhatsApp/Databases chat backups are stored. Delete them only if you do not plan to restore correspondence when reinstalling.
Make sure that important files are saved in the cloud|Check the folder Sent (sent files)|Clear the cache through the messenger settings|Delete duplicates media files-->
5. Folders with downloads and temporary files
Folder Download (or Downloads) is a classic place where garbage accumulates. The following are stored here:
- ๐ PDF and DOCX files, opened once
- ๐ต Music and podcasts from the browser
- ๐ฆ APK files of installed (and deleted) applications
- ๐ผ๏ธ Pictures from social networks
You can clear it manually or through Mi File Manager:
- Open
Files(folder icon on the desktop). - Go to
Categories โ Downloads. - Sort files by date or size.
- Select unnecessary ones and click
Delete.
For automatic cleaning, use Google Files (application Files from Google):
- ๐งน Go to the section
Cleaning. - ๐ Select
Large filesorUnused applications. - ๐๏ธ Confirm deletion.
Pay special attention to files with the extension .apk. These are application installation packages that remain after installation. You can safely delete them if the application is already installed. However, if you are saving APKs for future installation (for example, old versions of apps), move them to a separate folder.
Regular cleaning of the folder Download frees up to 1-2 GB of memory on most Xiaomi devices. Use sorting by size to quickly find the heaviest files.
6. Game folders: how to delete unnecessary data without losing progress
Modern mobile games (for example, PUBG Mobile, Free Fire or Honor of Kings) can take up to 5-8 GB on the device. At the same time, most of the data is stored in three places:
- ๐ฎ
/Android/obb/<package_name>/โ main game files (can be deleted only if the game is uninstalled) - ๐๏ธ
/Android/data/<package_name>/files/โ saves and cache - ๐ผ๏ธ
/storage/emulated/0/<GameName>/โ screenshots and gameplay recordings
To clear game data without losing progress:
- Open
Settings โ Applications โ Manage applications. - Select the game and press
Storage. - Click
Clear cache(notClear data!).
If the game supports cloud saves (for example, via Google Play Games or Mi Account), you can completely delete its data:
- Synchronize progress with the cloud in the game settings.
- Delete the game via
Settings โ Applications. - Delete folders
obbanddatafor this game manually. - Reinstall the game and restore progress from the cloud.
โ ๏ธ Attention: Games from Tencent (for example, PUBG Mobile or Call of Duty Mobile) can block your account with frequent reinstallations. Do not clear data more than once a month.
7. Hidden folders and technical junk: what can be removed by experienced people. users
For users with root access or TWRP Additional folders for cleaning are available. However, working with them requires caution. Here's what you can delete:
| Folder | Path | Description | Risks |
|---|---|---|---|
dalvik-cache |
/data/dalvik-cache/ |
Virtual machine cache Dalvik | Removal will speed up the first boot after cleaning, but may cause errors in applications |
log |
/data/log/ |
System and application logs | Safe, but may complicate problem diagnosis |
tombstones |
/data/tombstones/ |
Memory dumps when applications crash | Safe, but useful for debugging |
For cleaning via TWRP:
- Boot into TWRP (hold
Power + Volume upwhen turning on). - Select
Advanced โ File Manager. - Go to
/data/and delete folderslog,tombstones. - Do not touch
dalvik-cacheif you are not sure of the consequences.
For cleaning without root use the ADB command:
adb shell pm trim-caches 256M
This command will clear the cache of all applications, limiting its size to 256 MB.
โ ๏ธ Attention: Clearing /data/log/ may hide the causes of future crashes. If your Xiaomi frequently reboots or lags, first save the logs for diagnostics.
8. Automation of cleaning: MIUI tools and settings
Manual cleaning is effective, but time-consuming. Fortunately, MIUI and third-party applications offer tools for automatic optimization:
- ๐งน Built-in utility "Cleaning": located in
Settings โ Cleaning. Allows you to delete cache, unnecessary APKs, duplicate photos and large files. - โ๏ธ Cleaning scheduler: in the same utility you can configure automatic cleaning on a schedule (for example, once a week).
- ๐ Google Files: the Google application analyzes memory and suggests deleting unnecessary files, including cache and duplicates.
- ๐ ๏ธ SD Maid (requires root): deep cleaning of system folders, searching for "dead" files and remnants of deleted applications.
To set up automatic cleaning in MIUI:
- Open
Settings โ Cleaning. - Click on the gear icon (โ๏ธ) in the upper right corner.
- Enable the option
Auto-cleanand select the frequency (daily/weekly). - Mark the types of files to delete (cache, APK, temporary files).
Suitable for advanced users Tasker - an application for automation. With it, you can create a task that will:
- Clear the cache once every 3 days.
- Delete files from
Downloadolder than 30 days. - Notify about a large amount of garbage.
Example task for Tasker:
Profile: Clear cache (Time: 3:00, Repeat: every 3 days)Task:
1. Run the command: pm trim-caches 512M (ADB)
2. Delete files from /storage/emulated/0/Download/ older than 30 days
3. Send notification: "Cleanup complete!"
โ ๏ธ Attention: Automatic cleanup may remove important files unless exceptions are configured. Always check which folders are added to the "white list" in the utility settings.
The combination of the built-in MIUI utility and Google Files covers 90% of cleaning needs. For deep optimization, use SD Maid (only with root).
FAQ: Frequently asked questions about cleaning folders on Xiaomi
Is it possible to delete a folder Android completely?
No, this is the system folder that contains application data, cache and OBB files. Uninstalling it will crash most apps. However, inside it you can clear subfolders cache, obb (for deleted games) and data (cache of specific applications).
Why do some applications run slower after clearing the cache?
The cache speeds up the loading of frequently used data. After cleaning, the application has to download them again, which can cause temporary lags. Usually, the speed is restored after 1-2 launches of the app.
How to clear a folder DCIM/.thumbnailsif it is not visible in the file manager?
This folder is hidden by default. To see it:
- Open Mi File Manager.
- Click on the three dots in the upper right corner and select
Settings. - Enable the option
Show hidden files. - Go to
DCIMand delete the folder.thumbnails.
Or use the ADB command:
adb shell rm -rf /storage/emulated/0/DCIM/.thumbnails
What should you do if, after clearing the folders, the phone begins to overheat?
This can happen if you deleted files that are critical for the processor or GPU (for example, drivers in /vendor). Try:
- Reboot the device.
- Check the temperature in
Settings โ About phone โ Battery status. - If the problem persists, reset to factory settings (
Settings โ Advanced โ Recovery and reset).
Can I empty the folder MIUI/Extraif I do not use custom themes?
Even if you did not install the themes manually, the folder may contain system files necessary for correct operation interface. Clearing it can lead to:
- Resetting the wallpaper to standard.
- Disappearance of custom icons.
- Errors when applying themes from Mi Theme Store.
It is better not to touch this folder or create a backup copy first.