Does a Magisk module made your Android device bootloop, or you want just to unroot your device and clean Magisk of it? Then on this post I will share how to fix bootloop caused by Magisk module or uninstall Magisk completely.
Licosha — Magisk is the most popular root solution today for many people to get the
su command airing on Android devices.
The reason Magisk is so popular is because its rootless method, means Magisk can activate root commands without touching any files in the system directory. And not forget the modules system, allowing Android users to add extra functionalities and hacks to Android device through an easy one tap process.
But still, there are will always possibilites that playing with root command create unexpected turn of events that could made Android device bootloop, even though we (casual users) already very carefully following the module / tutorial instruction.
A. Force removing Magisk module
If we think a module has caused bugs or bootloop to our Android device but we still want to keep Magisk root and the other installed modules, we can force remove respective module from custom recovery menu:
- Custom recovery installed.
- Boot our Android device to recovery mode. In a bootloop state, we can press and hold the power button for a few seconds to force power off our device. After the screen is turned off, quickly press the recovery mode combination buttons (Depend on your Android device, usually press and hold volume down + power buttons for a few seconds and release them when device vibrate).
- Navigate using the custom recovery's file manager to
- Now all we need to do is delete the module folder and files we target. Usually Magisk modules will be placed under each folder of its module name inside the
Wipe Dalvik/cache, then reboot Android device.
B. Removing Magisk (unroot)
If deleting the module folder doesn't help fixing troubles or the troubles is not caused by a Magisk module, then the easiest way perhaps is removing the Magisk itself, or unrooting to remove all installed modules and other root operation effects.
B. 1. Restoring original boot partition
Restoring our Android device's original boot partition will remove the Magisk core itself but not the modules. So later if we reinstalling Magisk back, we can use the modules back in the same states just like before the original boot partition restored.
- Custom recovery installed.
- Device ROM's custom recovery backup of boot partition or original
The first way to restore original boot partition is by using the custom recovery backups. If we have made a boot partition backup using recovery menu before installing Magisk, then we could just boot our Android device to custom recovery and restore the boot partition backup.
The second way is by installing from your Android device ROM original
boot.img file. Depend on the installation method, it may be installed from
fastboot (flashing the
boot.img file into boot partition using PC for example) or custom recovery menu (flashing
boot.img to boot partition or zip install).
B. 2. Completely uninstall Magisk
Besides unrooting our Android device, completely uninstall Magisk will also remove all the modules installed.
The first way to easily uninstall Magisk completely from the core to the modules of course is through the Magisk app menu, choose
Uninstall Magisk ->
Complete Uninstall. But it's obvious this can only be done if our Android device still boot normally.
The second way is by using the Magisk uninstaller zip file. From the custom recovery menu, choose install option and select the Magisk Uninstaller zip file. You can download the latest Magisk uninstaller below:
Magisk Uninstaller 2021-01-17.zip (2.54 MB)
Actually Magisk made a backup of our Android device boot partition to
/data/magisk_backup_xxxxxxxxx when we installing Magisk core, so the Magisk uninstallation process will restoring the boot partition from it (aside deleting all modules).
So, if we find our Android device still has troubles even after Magisk uninstallation, just to make sure also do restore from original boot partition of our Android device like step B. 1. above even after Magisk uninstallation process done.
⭐ Credits ⭐
• topjohnwu @Github, the author of Magisk.