[GUIDE] How to apply a custom boot animation on HyperOS (No Root/Root)
This is fairly easy on HyperOS thanks to the system themes app, which allows you to change the boot animation when you apply a theme that includes one, but if you are on the global ROM like the most of us, you cannot import a custom boot animation to your liking, you're restricted to the ones on the store. So here I'll be discussing two easy methods (one rootless, one requires root) to get around this restriction.
First method (NO ROOT):
- Download a theme that has a boot animation:
In this example, we will be using this theme (theme://zhuti.xiaomi.com/detail/530deb19-19ba-40f5-80cf-8f2b141d0591), but it can literally be any theme that has a boot animation. Click that link or copy it to a browser, it should redirect you to the themes app, download but DON'T APPLY the theme.
- Locate the boot animation folder:
(On old Android versions, this can be done with any file manager, on the new versions you'll need adb or mtp connection).
Navigate to the following directory: /storage/emulated/0/Android/data/com.android.thememanager/files/MIUI/theme/.data/content/bootanimation/
Inside the folder, you will see this file: 90ab0dfb-93ff-45a9-977f-66d253e63c48.mrc, this is the boot animation of the theme.
Replace that boot animation with your custom bootanimation.zip file while keeping the original filename you found earlier (90ab0dfb-93ff-45a9-977f-66d253e63c48.mrc).
Apply the new boot animation!
Open the theme app, go to Customize Theme, select Boot Animation, choose the Pics V14 and Apply. That's it! You should see the new boot animation on the next reboot!
Second method (requires root!):
Perform all these actions in a root shell!
- Create these directories:
`mkdir /data/adb/boots`
`mkdir /data/system/theme/boots`
- Put your custom boot animation in the designated folder:
`cp /path/to/bootanimation.zip /data/adb/boots`
- Set the right permissions and ownership:
`chmod 775 /data/system/theme/boots`
`chmod 775 /data/adb/boots`
`chmod 755 /data/adb/boots/bootanimation.zip`
`chown system_theme:system_theme /data/system/theme/boots`
`chown system_theme:system_theme /data/adb/boots`
`chown system_theme:system_theme /data/adb/boots/bootanimation.zip`
- Create a script with these commands in /data/adb/service.d to inject the animation on boot time:
`#!/system/bin/sh`
`# Mount custom boot animation early on`
`nsenter -t 1 -m -- mount --bind /data/adb/boots /data/system/theme/boots`
`# Wait until system boot is completed`
`while [ "$(getprop sys.boot_completed)" != "1" ]; do`
`sleep 5`
`done`
`# Wait extra 15s`
`sleep 15`
`# un-mount the custom boot animation before system clears it`
`nsenter -t 1 -m -- umount /data/system/theme/boots`
- Make that script executable:
`chmod +x /data/adb/service.d/bootanim.sh`
That's it! Reboot your phone to see the new boot animation!
Notes: the reason why I suggest you put the bootanimation.zip file in a separate /data/adb/boots folder then mount it during boot, then un-mount it, is because one of system services clears the file later on, this is basically a hacky workaround.
P.S. if you like the boot animation in the picture, you can get it from here