• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

MIUI 10 De-bloat (Systemless+Automated) [Nov 14]

Search This thread

Sreekantt

Senior Member
Oct 30, 2015
960
2,002
MIUI changes things so fast. These config files are reported to break many things on the latest beta releases. Use at your own risk and feel free to experiment as this is a systemless mod.

Prerequisites -

1. Unlocked Boot loader with Magisk & TWRP on it. (You can do this on a locked boot loader & without root using adb but it is risky on MIUI 10 as few bloatware apps are deeply linked to system services in MIUI 10)

2. Terminal Debloater Magisk module. Download it here or from Magisk Manager.

3. Any Terminal Emulator app.

4. Basic de-bloat or Extreme de-bloat config file.

5. Backup (Although this module is harmless if you have magisk & TWRP properly working as we can reinstall all the apps within the TWRP if system breaks but just in case to be on safe side.)

6. Magisk Mount script- Download it here

*Please download this Magisk mount script prior to doing anything because we can reinstall apps by mounting Magisk in TWRP if something breaks.

Switch on USB debugging security settings & Install apps over USB toggles in developer options prior to the de-bloat as they need the MI account to turn them 'ON' which will be inaccessible after the de-bloating. After switching them ON, sign out of MI account, switch off MI cloud sync & Find device(If it's ON) and continue ahead.

If you have everything handy it should be a matter of few seconds to de-bloat.

We're only gonna deal with system apps for now. Uninstall the user spyware apps like UC, Opera browser, Microsoft & Amazon apps by yourself which comes with MIUI.

Guide for starters -

1. Copy this Basic de-bloat or Extreme de-bloat config file to the folder /cache in the root.

2. Reboot into Recovery

3. Install the Terminal Debloater Magisk module using the Magisk Manager.

4. Reboot into the system.

4. Open the terminal emulator app > Type 'su' and press enter > Grant root permissions > Type debloat and press enter.

4. You will see the options to debloat in various categories which are self explanatory. As we have the config file which has a predefined app list to de-bloat stored in /cache folder in root already. Type 'i' which says import config and press enter 2 times.

If you don't want to use the Basic de-bloat or Extreme de-bloat config file, Feel free to debloat independent apps.

5. Reboot 2 times and you're done most probably if nothing breaks.

Read from here if something breaks
If it breaks the system or causes boot-loop which shouldn't be the case as I'm using the same device and thoroughly tested it on 8.9.11, Don't worry! It's damn easy to reinstall all of them in one click by TWRP.

Did you download the Magisk Mount script which I asked to earlier ? If yes, just flash it with TWRP and the magisk will be mounted and accessible in TWRP file explorer. If you didn't download the script earlier, Just adb sideload it in recovery.

After mounting the Magisk in TWRP > Click on Advanced and go to file explorer.
Then delete the app folder of the system app you've uninstalled in /Magisk/terminal_debloater/system/app (/sbin/.core/img/terminal_debloater/system/app) or /Magisk/terminal_debloater/system/priv-app (/sbin/.core/img/terminal_debloater/system/priv-app) then that should undo it.

----------------------
I left out few apps even though they're considered bloatware because they're deeply linked into the system.
For example, Removing chrome breaks apps like Swift Key, Standard Notes, Twitter etc. in MIUI 10. We're gonna de-bloat most of the so called security services found in the security app but few services like app scanning which is found in MIUI Security components app is mandatory for the package manager to properly install apps from unknown sources. Considering all these, after testing it for few runs- I pinned down the apps which are safe to remove without any impact for my usage. It may vary with yours but feel free to suggest or remove any app line from this Basic de-bloat or Extreme de-bloat config file.

Apps which will be de-bloated in basic config and please suggest if I miss something.

Code:
[B]Removed[/B]
AnalyticsCore
AntiSpam
MiPicks
BugReport
facebook-appmanager
CloudService
FileExplorerGlobal
FileExplorer_old
Gmail2
Videos
Music2
Duo
InMipay
LatinImeGoogle
PaymentService
MiuiVideoPlayer
UpnpService
MSA-Global
GlobalTrendNews
Netflix_activation
XiaomiAccount
HybridPlatform
MiLinkService
MiCloudSync
HybridAccessory
SYSOPT
VsimCore
KSICibaEngine
YouDaoEngine
XMCloudEngine
SecurityAdd
SecurityCoreAdd
PlayAutoInstallStubApp
MiuiDaemon
WMService
BTProductionLineTool
TranslationService
MiuiScreenRecorder
Notes
Stk
PersonalAssistantGlobal
Browser
Calendar
CleanMaster
facebook-installer
facebook-services
GameCenterGlobal
GoogleFeedback
CloudServiceSysbase
YellowPage
CloudBackup
MiWebView
Music
Backup
SoundRecorder
MiVRFramework

[B]Bloatware but not removed[/B]
Battery & Performance, Power detector - breaks battery stats (Remove it on your own if you don't need it or you use alternatives like Better Battery Stats)

Bluetooth MIUI - comes in handy sometimes and linked to system Bluetooth service (Removed in Extreme de-bloat config file.)

Calculator - I didn't care to remove it (Removed in Extreme de-bloat config file.)

Chrome - breaks many apps

CIT & CIT QR - I think you can remove it if you don't need hardware tests (Removed in Extreme de-bloat config file.)

Clock - handy app linked to core services (Removed in Extreme de-bloat config file.)

Compass - You can remove if you don't use (Removed in Extreme de-bloat config file.)

Default print service, Google text to speech engine, MI Wallpaper, Live wallpaper picker, Photo screen saver, Photos, Quick ball, Print service recommendation, print spooler, talkback, Youtube, Drive, Maps, Updater, Audio effect, Wallpaper cropper, Weather & Weather service provider- You can remove all of these if you don't use and hopefully it wouldn't cause issues like chrome did. (Removed in Extreme de-bloat config file.)

Joyose - breaks default SMS app. You can install any other messages app and remove this (Removed in Extreme de-bloat config file.)

RTMICloudEngine - breaks Phone app. You can install Google Dialer app and remove this (Removed in Extreme de-bloat config file.)

MI Security components - breaks app installation

Sms extra - sometimes it breaks default SMS app (Removed in Extreme de-bloat config file.)

Downloads & MI drop, for some strange reason, they won't go away (Remove them with Titanium backup or adb commands below)

Files - needed by some apps which don't have storage permission like Exif data remover

Google Play services & Play store - Almost everybody needs it (You can remove google app)

Poco launcher - didn't include it in the config file as many wouldn't have a backup launcher in hand which causes system UI to crash (You can remove it by installing any launcher you prefer) (Removed in Extreme de-bloat config file.)

Scanner - Strangely, this app breaks the package manager and causes it to crash (Removed in Extreme de-bloat config file and package manager won't crash anymore)

Security - biggest bloatware of MIUI which can't be uninstalled as it's deeply integrated into settings to access permissions, data usage, battery stats etc (Go into settings of this app and switch off everything especially the security scan which scans every app and sends the data to cloud. 

Telemetry j service - It wouldn't go away with this magisk module. Disable it with Titanium backup app.

Updated and tested over new beta 8.9.20 (13/09/2018)

This is a new Extreme de-bloat config file. To use this config - Just follow the instructions which I have already mentioned above.

Debloated few other MIUI services like Dialer, SMS, Gallery apps & you can replace them with trusted alternatives of your choice. Removed RT MI Cloud SDK, Joyose, Xiaomi Service Framework(battery drainer) which were required by MIUI phone-SMS apps previously and we no longer need them as we have replaced most of the services.
This almost de-bloats everything including basic apps like Clock. Retained few services like battery & performance because removing such services causes some instability in settings app as they're deeply integrated but they do send data to Xiaomi IP addresses every minute which is very suspicious. Hence, use AF Wall+ or Net guard to block their network connections.

Few apps like Facebook services, Facebook app installer, Mi Drop refuse to uninstall with this Magisk Module. Kick them out using adb shell/Titanium backup app.
adb commands for removing leftovers
Code:
pm uninstall -k --user 0 com.facebook.katana
pm uninstall -k --user 0 com.facebook.system
pm uninstall -k --user 0 com.facebook.appmanager
pm uninstall -k --user 0 com.facebook.services
pm uninstall -k --user 0 com.xiaomi.midrop.overlay
pm uninstall -k --user 0 com.xiaomi.midrop
pm uninstall -k --user 0 com.mfashiongallery.emag
pm uninstall -k --user 0 com.miui.android.fashiongallery
 pm uninstall -k --user 0 com.miui.videoplayer.overlay

This is the maximum I could get in this de-bloating journey of MIUI 10 so far and it's pretty stable. You can turn off MIUI optimizations in developer options for better RAM management. (Beware! Permissions & DPI gets reset and it's pretty easy to dial them back.)

Update (14/11/2018)
Considering the new update of the module which needed the new config files for the import to work, I Updated the entire OP with the new config files.
Procedure is still the same but it needs the new config files.
You can download the new config files here Basic de-bloat / Extreme de-bloat.

If you are still using the old version and need the config files - Grab them here Basic de-bloat or Extreme de-bloat


Credits
@veez21 for his wonderful debloater module which is extremely safe & easy to use.
@mohan_168 for giving me the basic idea of bloatware in MIUI 9 which helped to fasten the things.
MIUI team for spoiling the beautiful MIUI(5/6/7) and filled it with bloatware ads. UC browser & Game booster...seriously ??
 
Last edited:

Onsite_Baba

Member
May 30, 2012
6
1
Bhavnagar
Worked, not sure why but it did not remove following apps on my device (have run the debloater twice but no luck):
Mi File Explorer
Duo
MSA
facebook-appmanager
facebook-installer
facebook-services

Also, somehow, now I can not access Dual Apps under settings, kindly help to resolve dual apps access
 

Sreekantt

Senior Member
Oct 30, 2015
960
2,002
Worked, not sure why but it did not remove following apps on my device (have run the debloater twice but no luck):
Mi File Explorer
Duo
MSA
facebook-appmanager
Afacebook-installer
facebook-services

Also, somehow, now I can not access Dual Apps under settings, kindly help to resolve dual apps access

You can uninstall Duo by hand now as it no longer linked to system. I'm looking into the Facebook-appmanager & facebook-installer. As of now they sound stubborn for a systemless uninstall. For now, I have blocked the from accessing internet through AfWall+.

Meanwhile, you can remove the leftovers with adb commands

adb shell
pm uninstall -k --user 0 com.facebook.katana
pm uninstall -k --user 0 com.facebook.system
pm uninstall -k --user 0 com.facebook.appmanager
pm uninstall -k --user 0 com.facebook.services

MSA & File explorer were removed with the above module for me but you can try using adb commands to uninstall them as they're pretty safeto remove.

pm uninstall -k --user 0 com.miui.systemAdSolution

Sorry, I don't have any idea about Dual apps as I'm not sure about an app which is responsible for dual apps to work. You can try reinstalling suspected system apps by trial & error method and check which app is responsible for that. Although I consider such services as bloat which constantly calls home but your opinion may vary.
 
Last edited:
  • Like
Reactions: Skolotaie

zengraviz

Senior Member
Mar 8, 2013
135
10
Surabaya
Help when i install the module it said magisk not installed but i have magisk 17.1 up and running! What is happening and how to fix this
 
Last edited:

u_knw_who

Senior Member
May 25, 2014
243
45
mumbai
Xiaomi Poco F1

Attachments

  • Screenshot_2018-09-15-07-55-44.png
    Screenshot_2018-09-15-07-55-44.png
    135 KB · Views: 4,316

uremytoy

Senior Member
Feb 25, 2012
650
169
Białystok
www.xperiasite.pl
Encryption zip has magisk. It's older version but it's working. Just update it. It's working fine. Installing it from zip didn't work for me too

Wysłane z mojego POCOPHONE F1 przy użyciu Tapatalka
 

Sarvesh7x

Senior Member
Jul 14, 2017
53
5
so after your config debloat.. can i still login to my mi account? also i want the sync to stay
 

mohan_168

Senior Member
Apr 14, 2013
341
244
Bangalore
We are gonna de-bloat most of the so called security services found in the security app but few services like app scanning which is found in MIUI Security components app is mandatory for the package manager to properly install apps from unknown sources.


For this, you Can download - Package installer 8.1.0-4879956 By Google LLC.
You can uninstall the bloat from Xiaomi

---------- Post added at 07:27 AM ---------- Previous post was at 07:26 AM ----------

so after your config debloat.. can i still login to my mi account? also i want the sync to stay

Do you want to sync to Xiaomi? Why not sync to Google?
You can skip login to Xiaomi when you install miui.
 

Sreekantt

Senior Member
Oct 30, 2015
960
2,002
We are gonna de-bloat most of the so called security services found in the security app but few services like app scanning which is found in MIUI Security components app is mandatory for the package manager to properly install apps from unknown sources.


For this, you Can download - Package installer 8.1.0-4879956 By Google LLC.
You can uninstall the bloat from Xiaomi

Cool. I thought so but was too lazy. That's a neat idea. Right now blocking those all left over bloat with AF wall+.
 

Sarvesh7x

Senior Member
Jul 14, 2017
53
5
Can someone explain the put that file in cache part? I don't know where cache folder is, and also the file show 410 forbidden error to me
 

Top Liked Posts

  • There are no posts matching your filters.
  • 25
    MIUI changes things so fast. These config files are reported to break many things on the latest beta releases. Use at your own risk and feel free to experiment as this is a systemless mod.

    Prerequisites -

    1. Unlocked Boot loader with Magisk & TWRP on it. (You can do this on a locked boot loader & without root using adb but it is risky on MIUI 10 as few bloatware apps are deeply linked to system services in MIUI 10)

    2. Terminal Debloater Magisk module. Download it here or from Magisk Manager.

    3. Any Terminal Emulator app.

    4. Basic de-bloat or Extreme de-bloat config file.

    5. Backup (Although this module is harmless if you have magisk & TWRP properly working as we can reinstall all the apps within the TWRP if system breaks but just in case to be on safe side.)

    6. Magisk Mount script- Download it here

    *Please download this Magisk mount script prior to doing anything because we can reinstall apps by mounting Magisk in TWRP if something breaks.

    Switch on USB debugging security settings & Install apps over USB toggles in developer options prior to the de-bloat as they need the MI account to turn them 'ON' which will be inaccessible after the de-bloating. After switching them ON, sign out of MI account, switch off MI cloud sync & Find device(If it's ON) and continue ahead.

    If you have everything handy it should be a matter of few seconds to de-bloat.

    We're only gonna deal with system apps for now. Uninstall the user spyware apps like UC, Opera browser, Microsoft & Amazon apps by yourself which comes with MIUI.

    Guide for starters -

    1. Copy this Basic de-bloat or Extreme de-bloat config file to the folder /cache in the root.

    2. Reboot into Recovery

    3. Install the Terminal Debloater Magisk module using the Magisk Manager.

    4. Reboot into the system.

    4. Open the terminal emulator app > Type 'su' and press enter > Grant root permissions > Type debloat and press enter.

    4. You will see the options to debloat in various categories which are self explanatory. As we have the config file which has a predefined app list to de-bloat stored in /cache folder in root already. Type 'i' which says import config and press enter 2 times.

    If you don't want to use the Basic de-bloat or Extreme de-bloat config file, Feel free to debloat independent apps.

    5. Reboot 2 times and you're done most probably if nothing breaks.

    Read from here if something breaks
    If it breaks the system or causes boot-loop which shouldn't be the case as I'm using the same device and thoroughly tested it on 8.9.11, Don't worry! It's damn easy to reinstall all of them in one click by TWRP.

    Did you download the Magisk Mount script which I asked to earlier ? If yes, just flash it with TWRP and the magisk will be mounted and accessible in TWRP file explorer. If you didn't download the script earlier, Just adb sideload it in recovery.

    After mounting the Magisk in TWRP > Click on Advanced and go to file explorer.
    Then delete the app folder of the system app you've uninstalled in /Magisk/terminal_debloater/system/app (/sbin/.core/img/terminal_debloater/system/app) or /Magisk/terminal_debloater/system/priv-app (/sbin/.core/img/terminal_debloater/system/priv-app) then that should undo it.

    ----------------------
    I left out few apps even though they're considered bloatware because they're deeply linked into the system.
    For example, Removing chrome breaks apps like Swift Key, Standard Notes, Twitter etc. in MIUI 10. We're gonna de-bloat most of the so called security services found in the security app but few services like app scanning which is found in MIUI Security components app is mandatory for the package manager to properly install apps from unknown sources. Considering all these, after testing it for few runs- I pinned down the apps which are safe to remove without any impact for my usage. It may vary with yours but feel free to suggest or remove any app line from this Basic de-bloat or Extreme de-bloat config file.

    Apps which will be de-bloated in basic config and please suggest if I miss something.

    Code:
    [B]Removed[/B]
    AnalyticsCore
    AntiSpam
    MiPicks
    BugReport
    facebook-appmanager
    CloudService
    FileExplorerGlobal
    FileExplorer_old
    Gmail2
    Videos
    Music2
    Duo
    InMipay
    LatinImeGoogle
    PaymentService
    MiuiVideoPlayer
    UpnpService
    MSA-Global
    GlobalTrendNews
    Netflix_activation
    XiaomiAccount
    HybridPlatform
    MiLinkService
    MiCloudSync
    HybridAccessory
    SYSOPT
    VsimCore
    KSICibaEngine
    YouDaoEngine
    XMCloudEngine
    SecurityAdd
    SecurityCoreAdd
    PlayAutoInstallStubApp
    MiuiDaemon
    WMService
    BTProductionLineTool
    TranslationService
    MiuiScreenRecorder
    Notes
    Stk
    PersonalAssistantGlobal
    Browser
    Calendar
    CleanMaster
    facebook-installer
    facebook-services
    GameCenterGlobal
    GoogleFeedback
    CloudServiceSysbase
    YellowPage
    CloudBackup
    MiWebView
    Music
    Backup
    SoundRecorder
    MiVRFramework
    
    [B]Bloatware but not removed[/B]
    Battery & Performance, Power detector - breaks battery stats (Remove it on your own if you don't need it or you use alternatives like Better Battery Stats)
    
    Bluetooth MIUI - comes in handy sometimes and linked to system Bluetooth service (Removed in Extreme de-bloat config file.)
    
    Calculator - I didn't care to remove it (Removed in Extreme de-bloat config file.)
    
    Chrome - breaks many apps
    
    CIT & CIT QR - I think you can remove it if you don't need hardware tests (Removed in Extreme de-bloat config file.)
    
    Clock - handy app linked to core services (Removed in Extreme de-bloat config file.)
    
    Compass - You can remove if you don't use (Removed in Extreme de-bloat config file.)
    
    Default print service, Google text to speech engine, MI Wallpaper, Live wallpaper picker, Photo screen saver, Photos, Quick ball, Print service recommendation, print spooler, talkback, Youtube, Drive, Maps, Updater, Audio effect, Wallpaper cropper, Weather & Weather service provider- You can remove all of these if you don't use and hopefully it wouldn't cause issues like chrome did. (Removed in Extreme de-bloat config file.)
    
    Joyose - breaks default SMS app. You can install any other messages app and remove this (Removed in Extreme de-bloat config file.)
    
    RTMICloudEngine - breaks Phone app. You can install Google Dialer app and remove this (Removed in Extreme de-bloat config file.)
    
    MI Security components - breaks app installation
    
    Sms extra - sometimes it breaks default SMS app (Removed in Extreme de-bloat config file.)
    
    Downloads & MI drop, for some strange reason, they won't go away (Remove them with Titanium backup or adb commands below)
    
    Files - needed by some apps which don't have storage permission like Exif data remover
    
    Google Play services & Play store - Almost everybody needs it (You can remove google app)
    
    Poco launcher - didn't include it in the config file as many wouldn't have a backup launcher in hand which causes system UI to crash (You can remove it by installing any launcher you prefer) (Removed in Extreme de-bloat config file.)
    
    Scanner - Strangely, this app breaks the package manager and causes it to crash (Removed in Extreme de-bloat config file and package manager won't crash anymore)
    
    Security - biggest bloatware of MIUI which can't be uninstalled as it's deeply integrated into settings to access permissions, data usage, battery stats etc (Go into settings of this app and switch off everything especially the security scan which scans every app and sends the data to cloud. 
    
    Telemetry j service - It wouldn't go away with this magisk module. Disable it with Titanium backup app.

    Updated and tested over new beta 8.9.20 (13/09/2018)

    This is a new Extreme de-bloat config file. To use this config - Just follow the instructions which I have already mentioned above.

    Debloated few other MIUI services like Dialer, SMS, Gallery apps & you can replace them with trusted alternatives of your choice. Removed RT MI Cloud SDK, Joyose, Xiaomi Service Framework(battery drainer) which were required by MIUI phone-SMS apps previously and we no longer need them as we have replaced most of the services.
    This almost de-bloats everything including basic apps like Clock. Retained few services like battery & performance because removing such services causes some instability in settings app as they're deeply integrated but they do send data to Xiaomi IP addresses every minute which is very suspicious. Hence, use AF Wall+ or Net guard to block their network connections.

    Few apps like Facebook services, Facebook app installer, Mi Drop refuse to uninstall with this Magisk Module. Kick them out using adb shell/Titanium backup app.
    adb commands for removing leftovers
    Code:
    pm uninstall -k --user 0 com.facebook.katana
    pm uninstall -k --user 0 com.facebook.system
    pm uninstall -k --user 0 com.facebook.appmanager
    pm uninstall -k --user 0 com.facebook.services
    pm uninstall -k --user 0 com.xiaomi.midrop.overlay
    pm uninstall -k --user 0 com.xiaomi.midrop
    pm uninstall -k --user 0 com.mfashiongallery.emag
    pm uninstall -k --user 0 com.miui.android.fashiongallery
     pm uninstall -k --user 0 com.miui.videoplayer.overlay

    This is the maximum I could get in this de-bloating journey of MIUI 10 so far and it's pretty stable. You can turn off MIUI optimizations in developer options for better RAM management. (Beware! Permissions & DPI gets reset and it's pretty easy to dial them back.)

    Update (14/11/2018)
    Considering the new update of the module which needed the new config files for the import to work, I Updated the entire OP with the new config files.
    Procedure is still the same but it needs the new config files.
    You can download the new config files here Basic de-bloat / Extreme de-bloat.

    If you are still using the old version and need the config files - Grab them here Basic de-bloat or Extreme de-bloat


    Credits
    @veez21 for his wonderful debloater module which is extremely safe & easy to use.
    @mohan_168 for giving me the basic idea of bloatware in MIUI 9 which helped to fasten the things.
    MIUI team for spoiling the beautiful MIUI(5/6/7) and filled it with bloatware ads. UC browser & Game booster...seriously ??
    2
    updated debloat script, briefly tested on Global Stable 10.2.3.0 & Global BETA 9.3.18
    https://www.androidfilehost.com/?fid=1395089523397924159

    have fun. report if you find any issues :)
    2
    here's my initial config for 9.3.1 beta & 10.2.2 stable .
    i only tested this list for bootloops and reboots, core system stability, dependencies of system apps and drain/deepsleep. did not test any further than that. YMMV
    9.3.1_import-debloat.txt
    2
    Try this one, it's safe and good. It's from Note 7 forum, but it works on Poco or other Xiaomis.

    https://forum.xda-developers.com/re...dmi-note-7-miui-10-3-5-0-root-t3928466/page15
    2
    Used the new extreme debloat. Can you please re-upload Google dialler. It's been removed. And any recommendations for messages ?

    You can find it here
    You can use Signal for SMS too. If you want something simple - Google Messages

    Did anyone try it on mi 8? How's it working?

    It should work on any MIUI 10 device as they have the same bloatware.