Hand-cleaning Xiaomi garbage: how to free memory without apps

Xiaomi MIUI-based smartphones slow down over time due to the accumulation of unnecessary files: app cache, remnants of deleted programs, temporary system data and media duplicates. Even new models like the Redmi Note 13 Pro+ or POCO F6 after 6-8 months of active use begin to โ€œbrakeโ€ when opening a gallery or switching between tasks. Built-in cleaning tools (for example, Security โ†’ Cleanup) remove only part of the garbage, leaving deep system files intact.

This article will teach you how to manually find and remove hidden debris on Xiaomi without resorting to third-party โ€œcleanersโ€ that often collect user data. We will analyze safe methods for all versions of MIUI 12-14, including hidden folders, cache of system applications and optimization of storage without risking damage to the OS. Important: manual cleaning requires accuracy โ€“ deleting some files can cause malfunctions of individual functions (for example, weather widgets or themes).

Why MIUI In-Based Cleaning Is Ineffective

The built-in security tool โ†’ Cleanup in Xiaomi removes only:

  • ๐Ÿ—‘๏ธ Cache of user applications (non-system)
  • ๐Ÿ“ Temporary download files (Download folder)
  • ๐Ÿ“ธ Gallery miniatures (folder.thumbnails)
  • ๐Ÿ”„ Update logs (if not protected by the system)

But he doesn't touch:

  • ๐Ÿงน Residues of uninstalled applications (folders in /data/data/)
  • ๐Ÿ“ฆ Cache of system services (e.g., com.miui.system)
  • ๐Ÿ”„ Error Logs and Memory Dumps (Folder /data/anr/)
  • ๐Ÿ“‚ Duplicate media files that are automatically created (e.g. edited photos in MIUI Gallery)

In addition, MIUI aggressively caches data to speed up the interface, but does not always clean it correctly. For example, the /data/system/package_cache/ folder can occupy up to 1-1.5 GB on devices with a large number of installed / remote applications.

โš ๏ธ Warning: Donโ€™t use apps like Clean Master or CCleaner to clean Xiaomi. They often delete critical files MIUI, which leads to bugs in the themes, widgets, and even the inability to update the system.

๐Ÿ“Š How often do you clean your Xiaomi garbage?
Once a week.
Once a month
Only when the phone starts to brake
Never cleaned.

Preparing for manual cleaning: what to do in advance

Before you start deleting files, follow the mandatory preparatory steps:

  1. Back up your important data. Use Settings โ†’ Google โ†’ Backup or manually copy files from DCIM, Documents, and Download folders to your PC.
  2. Check the space. Go to Settings โ†’ About Phone โ†’ Storage to estimate the amount of garbage. If less than 10% of the total memory is free, cleaning is critical.
  3. Activate the display of hidden files. To do this, connect your phone to your PC and in Windows/Linux Explorer, turn on the option โ€œShow hidden files and foldersโ€.
  4. Charge your phone at least 50 percent. Long-term file operations drain the battery faster than usual.

If you plan to clean your system folders (e.g. /data/), turn on the developer mode:

  1. Go to Settings. โ†’ The phone.
  2. Tap 7 times on the MIUI version.
  3. Return to Settings โ†’ Additional โ†’ For developers and activate Debugging over USB.

Checked vacant storage space|Created a backup of important files|Display of hidden folders enabled|Developer mode activated (if necessary)|The phone is charged at 50% or more-->

Cleaning the cache of user and system applications

App cache is the main source of garbage on Xiaomi. Unlike these applications (which contain settings and saves), the cache can be deleted without risk to the program. However, MIUI system applications (for example, com.miui.home or com.android.systemui) require caution.

Method 1: Through Application Settings

The safest way is:

  1. Open Settings โ†’ Applications โ†’ Application Management.
  2. Select an app (such as YouTube or Facebook).
  3. Slip the vault. โ†’ Clear the cache.
  4. For deep cleaning, click Clear Data, but note that this will reset the app settings.

Method 2: Mass cleaning of cache (ADB required)

For power users: You can clear the cache of all applications immediately through the ADB command. Connect your phone to your PC and do:

adb shell pm trim-caches 1000G

This command tells the system to release cache up to 1000 GB (actually all available).

โš ๏ธ Warning: Do not clear system applications like com.miui.securitycenter or com.android.phone via ADB. This may make it impossible to make calls or use mobile internet.

Cache typeSize (approximately)Can I remove it?Effects of removal
Cache of user applicationsFrom 50MB to 2GBYes.Applications will be loaded longer at the first launch
Cache of system applications (com.miui.*)From 200MB to 1GBYeah, but be careful.Possible interface lags before rebooting
Dalvik cache (/data/dalvik-cache/)300MB to 1.5GBOnly through recovery.Accelerates the system after restarting
Cash Google Play ServicesFrom 100MB to 500MBYes.Temporary problems with geolocation and push notifications

Removing Remnants of Remote Applications

When uninstalling applications via Settings or Google Play, Xiaomi often has:

  • ๐Ÿ“‚ Folders with settings in /data/data/ (e.g. /data/data/com.whatsapp/)
  • ๐Ÿ—ƒ๏ธ Files in /sdcard/Android/data/ (game cache, downloads)
  • ๐Ÿ“œ Database records packages.xml (may cause errors when installing new versions of applications)

To find and remove these residues:

  1. Connect your phone to your PC and open the /sdcard/Android/data/ folder (you need a root or ADB Explorer).
  2. Find folders with names of remote applications (for example, com.tencent.mm for WeChat).
  3. Delete them manually. If the folder is not deleted, use the ADB command: adb shell rm -rf /sdcard/Android/data/com.

To clean /data/data/, you will need root rights or MIUI Hidden Settings. Without root, you can only view content through ADB:

adb shell ls /data/data/

๐Ÿ’ก

If you install/remove applications frequently, use App Cloner to create a sandbox to avoid contamination of the main system with file residues.

Cleaning system folders: what can be removed without risk

Xiaomi has several system folders that can be manually cleaned, and below is a list of safe directories to remove and remove:

folderWayWhat it keeps.How to clean up
.thumbnails/sdcard/DCIM/.thumbnailsGallery miniaturesDelete all contents
anr/data/anr/Application error logsDelete all files with the.trace extension
lost.dir/sdcard/lost.dir/Recovered files after failuresCheck the contents before deleting
package_cache/data/system/package_cache/Cache of installed packagesRemove everything (root or ADB required)
log/sdcard/MIUI/log/MIUI's logsDelete files older than 7 days

To clean folders in /data/ or /system/, be sure to use ADB, as the standard conductor does not have access.

adb shell rm -rf /data/anr/*


adb shell rm -rf /data/system/package_cache/*

The /sdcard/MIUI/debug_log/ folder can be cleaned completely, containing debugging logs that are created when crashes occur, and removing them does not affect the system, but frees up to 500 MB of space on active devices.

How to clean Dalvik cache without root?
To clean the root-free Dalvik cache, restart the phone to recovery mode (clutch Power + Volume up), then select Wipe & Reset โ†’ Wipe Dalvik Cache. This method is safe and recommended by Xiaomi to eliminate lags after updates.

Storage optimization: search and removal of duplicates

Xiaomi automatically creates duplicate media files in several cases:

  • ๐Ÿ“ธ When editing a photo in MIUI Gallery (original + edited version)
  • ๐ŸŽต When downloading music via Mi Music (cache + original files)
  • ๐Ÿ“ When using Application Clone or Second Space functions

To search for duplicates:

  1. Install Files by Google (it has a built-in duplicate search tool).
  2. Open the Cleanup tab and select Duplicate Files.
  3. Check the results manually โ€“ automatic tools sometimes mistakenly identify similar files as duplicates.

Pay special attention to the folders:

  • /sdcard/DCIM/.thumbnails are thumbnails that can be completely removed.
  • /sdcard/Pictures/Screenshots โ€“ Screenshots are often duplicated when created through different methods (e.g. gesture and buttons).
  • /sdcard/MIUI/Gallery/cloud is the cache of cloud albums.

โš ๏ธ Warning: Do not delete the /sdcard/MIUI/Gallery/editor folder completely - it contains temporary files to edit the photo. Delete only content older than 30 days.

Cleaning up the cache of Google Play Services and other services

Google Play Services and the Google Play Store are actively cacheing data to speed up work, but their cache is rarely cleared automatically, and on Xiaomi, these services can take up to 800 MB-1 GB of space.

To clean them without risk to the system:

  1. Go to Settings โ†’ Applications โ†’ Application Management.
  2. Find Google Play Services and Google Play Store.
  3. In each of them, tap the Storage โ†’ Clear the cache.
  4. Restart your phone โ€“ this is necessary for the correct recovery of services.

If after cleaning there are problems with:

  • ๐Ÿ“ Geolocation โ€“ reinstall updates for Google Play Services in the app settings.
  • ๐Ÿ“ฅ By downloading from the Play Market โ€“ clear the data from Google Play bootloader (com.android.vending).
  • ๐Ÿ”” Push notifications โ€“ check Google Play Services in Settings โ†’ Accounts โ†’ Google.

To thoroughly clean the cache of Google Services Framework (responsible for account synchronization), use ADB:

adb shell pm clear com.google.android.gsf

After this command, you will have to re-enter the password from your Google account.

๐Ÿ’ก

Clearing the Google Play Services cache may temporarily interrupt geolocation-dependent services (such as maps or taxis) and all functions will be restored after the reboot.

Cleaning Automation: How to Reduce Garbage Accumulation

To reduce the risk of manual cleaning, set up Xiaomi to automatically reduce garbage:

  1. Turn off auto-save media from instant messengers: On WhatsApp: Settings โ†’ Data โ†’ Media auto-boot โ†’ disable for mobile data. On Telegram: Settings โ†’ Data and Memory โ†’ Media auto-boot โ†’ Select Never.
  2. Limit cache for individual apps: On YouTube, set the โ†’ Background playback โ†’ Cache settings to a minimum. On Google Chrome, clear history and cache once a week through โ‹ฎ โ†’ History โ†’ Clear data.
  3. Set up cleaning when connecting to Wi-Fi: In Settings โ†’ Battery โ†’ Power Saving Mode, activate Cleanup when connecting to charging.

For advanced users, use Tasker or MacroDroid to create automatic cache cleanup tasks, such as setting up a weekly.thumbnails folder cleanup or removing old logs from /sdcard/MIUI/log/.

If you frequently install APK- files from third-party sources, check the /sdcard/Download folder regularly for unnecessary.apk files. These can take up hundreds of megabytes, especially if you're testing a lot of applications.

FAQ: Frequent questions about Xiaomi cleanup

Can I clean the /data/app/ folder manually?
No, this folder contains the installed applications, and if you clean it, you'll delete all the programs, including the system ones. Use Settings โ†’ Applications to uninstall.
Why do some applications run slower after cleaning the cache?
Cache speeds up the loading of frequently used data, and once cleaned, applications have to re-download and process information, which temporarily slows down their work, and in 1-2 days, the speed will return to normal.
How to clear the MIUI Launcher cache without resetting settings?
Run the command via ADB: adb shell pm clear com.miui.home This will reset desktop settings (wallpaper, widgets), but will not delete applications or data.
What if photos from the gallery are missing after cleaning?
Check the /sdcard/DCIM/.thumbnails folder โ€“ thumbnails may have been deleted and originals left in /sdcard/DCIM/Camera. If files are missing, use a data recovery software like DiskDigger.
How often should you clean your garbage on Xiaomi?
Recommended frequency: App cache every 1-2 weeks; System logs (/data/anr/, /sdcard/MIUI/log/) once a month; Media duplicates every 3 months; Dalvik cache only at noticeable lags or after MIUI updates.