If you are a Xiaomi user and MIUI is boring, unlock bootloader of Xiaomi device and install custom ROM! So, what is this custom ROM? Custom ROMs are custom build versions of Android. It is the perfect solution to improve performance of your device and get a different user experience with additional features. However, you need to unlock bootloader of your Xiaomi device to install custom ROMs. In this guide, you will learn what the terms “Bootloader” and “Custom ROM” mean, how to unlock bootloader of your Xiaomi device, how to install custom ROM, list of best custom ROMs and how to revert to stock ROM.
What is Bootloader and Custom ROM?
Bootloader in Android devices is software part that starts the Android OS of device. When you turn on your device, bootloader loads the operating system and other system components, and system boots successfuly. Android devices’ bootloader is locked for security reasons, which allows your device to run only with its stock firmware. Unlock bootloader gives full access to device and custom ROMs can be installed.
Custom ROM is an OS different from the stock firmware of your device. Custom ROMs are being prepared for almost Android devices, these ROMs prepared by community developers aim to expand features of device, improve performance, customized user interface or be able to experience newer Android versions beforehand. If you have been using low-end or midrange Xiaomi device for a long time, you must have encountered MIUI bugs. Lags in daily use, low FPS in games. Your device is already EOL (no more updates) so you just watch new features, and your low Android version doesn’t support next generation apps. That’s why you can get a much improved Xiaomi device experience with unlock bootloader and completing custom ROM installation.
How to Unlock Bootloader of Xiaomi Device?
We can start the unlock bootloader process of our Xiaomi device. Firstly, if you don’t have Mi Account on your device, create Mi Account and sign in. Because Mi Account is required for bootloader unlocking, we have to apply for bootloader unlocking to Xiaomi. First, enable the developer options, go “My Device” in settings menu, then tap “MIUI Version” 7 times to enable developer mode, if it asks for your password, enter it and confirm.
- We can start the Xiaomi unlock bootloader process now. After enabling developer mode, find “Additional Settings” section in Settings and select “Developer Options”. In developer options menu, find “OEM Unlock” option and enable it. You should go to “Mi Unlock status” section, from this section you can match your Mi Account and apply to Xiaomi side for unlock bootloader process. Your apply is approved after 7 days and you can continue unlock bootloader process. If your device is an EOL (end-of-life) device and you are not receiving MIUI updates, you don’t need to wait for this period, continue below.
Just press once instead of adding an Mi Account! If your device is up-to-date and still receiving updates (not EOL), your 1-week unlock period has begun. If you click that button continuously, your duration will increase to 2 – 4 weeks.
- In the next step, we need install “Mi Unlock” utility from official Xiaomi webpage. Unlock bootloader process requires a PC. After installation Mi Unlock to PC, sign in with your Mi Account. It’s important that you log into with your Mi Account on your Xiaomi device, it will not work if you login with different accounts. After that, shut down your phone manually, and hold Volume down + Power button to enter Fastboot mode. Connect your phone to PC using USB cable and click “Unlock” button. If your device is not visible in Mi Unlock, it’s recommended to install ADB & Fastboot drivers.
Unlock bootloader process will delete all your userdata, and ome features which require high security level (e.g., Find device, added-value services, etc.) will no longer be available. Also, since Google SafetyNet verification will fail, and device will appear as uncertified. This will cause problems in banking and other high-security apps.
How to Install Custom ROM?
Unlock bootloader of your Xiaomi device and installing custom ROM is a great way to expand your device’s features and customize user experience. Next is the custom ROM installation process, now bootloader is unlocked and there is no obstacle for installation. We need a custom recovery for installation. Android Recovery is part where the OTA (over-the-air) update packages of device are installed. All Android devices have an Android recovery partition, from which system updates are installed. Only stock system updates can be installed with stock recovery. We need a custom recovery to install custom ROM, and best solution for this is of course TWRP (Team Win Recovery Project).
TWRP (Team Win Recovery Project) is a custom recovery project that has been around for many years. With TWRP, which has very advanced tools, you can backup most important parts of the device, access system files and much more experimental operations, as well as installing custom ROMs. There are alternative projects based on TWRP, such as OFRP (OrangeFox Recovery Project), SHRP (SkyHawk Recovery Project), PBRP (PitchBlack Recovery Project), etc. In addition to these, there are additional recoverys next to custom ROM projects, current projects are installed with their own recovery (e.g LineageOS can installed with LineageOS Recovery; Pixel Experience is also can installed with Pixel Experience Recovery).
As a result, custom recovery should be installed first for custom ROM installation. You can find our TWRP installation guide from here, this applies to all Android devices including Xiaomi.
Custom ROM Installation
For custom ROM installation, you must first find a eligible package for your device, device codenames are used for this. Before, find out your device codename. Xiaomi has given codename to all devices. (e.g. Xiaomi 13 is “fuxi”, Redmi Note 10S is “rosemary”, POCO X3 Pro is “vayu”) This part is important because you flash wrong devices ROM/Recovery and your device will be bricked. If you don’t know the codename of your device, you can find your device codename from our device specifications page.
Check out our article here to choose the custom ROM that suits you, list of best custom ROMs available. Custom ROM installation process can be divided into two, first is flashable custom roms, which are the most common ones, and other is fastboot custom ROMs. Fastboot custom ROMs installed via fastboot are quite rare, so we’ll go with flashable custom ROMs. Custom ROMs are also divided into two. GApps versions with GMS (Google Mobile Services), and vanilla versions without GMS. If you are installing a vanilla custom ROM and want to use Google Play services, you will need to install GApps package after installation. With the GApps (Google Apps) package, you can add GMS to your vanilla custom ROM.
- First, reboot your device in recovery mode. We will explain based on TWRP recovery, other custom recoverys basically works with same logic. If you have a PC, you can install directly with”ADB Sideload” method. For this, follow the TWRP Advanced > ADB Sideload path. Activate sideload mode and connect device to the computer. Then start installation directly with “adb sideload filename.zip” command, so you won’t need to copy custom ROM .zip file to your device. Optionally, you can also install GApps and Magisk packages in the same way.
- If you don’t have a computer and cannot use ADB Sideload method, you should install custom ROM package from device. For this, get package to your device, if the internal storage is encrypted and cannot be decrypted, you can’t access package file and you can continue installation with USB-OTG or micro-SD. After doing this part, enter the “Install” section from the TWRP main menu, storage options will appear. Find and flash the package, you can also optionally install the GApps and Magisk packages as well.
When you’re done, go back to the TWRP main menu, continue from “Reboot” section at bottom right and reboot your device. You have successfully completed the custom ROM installation, wait for device to first boot and enjoy.
How to revert to Stock ROM?
You have successfully installed custom ROM on your Xiaomi device, but you may want the device to return to its default stock firmware, there may be many reasons (maybe device unstable and buggy, or you need Google SafetyNet verification, or you need to send device to technical service and you may want the device to be under warranty.) In this part, we will talk about how to revert your Xiaomi device to stock ROM.
There are two ways for this; first is flashable MIUI firmware installation from recovery. And other is MIUI installation via fastboot. We recommend fastboot installation, but recovery installation is the same thing. Since the fastboot way requires a PC, those who don’t have a computer can continue with recovery way. The best way to get latest fastboot and recovery MIUI versions is to use MIUI Downloader Enhanced. With MIUI Downloader Enhanced, the new and advanced version of our MIUI Downloader app developed by us, you can access the latest MIUI versions early, get MIUI ROMs from different regions, check MIUI 15 and Android 14 eligibility and much more, nore information about app is available.
Stock MIUI Firmware Installation with Recovery Method
This is easiest way to revert your Xiaomi device to stock ROM, you just need to get MIUI Downloader Enhanced and install required MIUI version on device. In this way, you will be able to obtain the required MIUI version on the device and you will be able to perform the installation process directly from device. During the switching from custom ROM to stock ROM, your internal storage must be wiped, otherwise the device will not boot. That’s why you need to somehow back up your necessary data on device.
- Open MIUI Downloader Enhanced, MIUI versions will meet you on the homescreen, select version you want and continue. Then the region selection section will come (Global, China, EEA, etc.) continue by selecting region you want. Then you will see the fastboot, recovery and incremental OTA packages, select recovery package and start the installation process. It may take some time depending on recovery package size and your bandwith.
- Then reboot into recovery mode. Find your stock MIUI recovery package, select and start the stock MIUI installation process. Installation process may take a few minutes, after it’s completed, you need to perform “Format Data” operation. To make the device completely factory settings, finally, perform format userdata with “Format Data” option from “Wipe” section. After the processes are completed successfully, you can restart your device. You have successfully switched your device to stock ROM from custom ROM.
Stock MIUI Firmware Installation with Fastboot Method
If you have a PC, most healthiest and effortless way to revert your Xiaomi device to stock ROM is, absolutely flashing stock MIUI firmware via fastboot. With fastboot firmware, all system images of device are re-flashed, so device completely restored to factory settings. You don’t need to perform additional operations such as format data, so it’s more effortless than recovery method. Just get fastboot firmware package, unpack firmware and run the flashing script. Also in this process, all your data will be deleted, don’t forget to take your backups. For this process we have to use Mi Flash Tool, you can get it here.
- Open MIUI Downloader Enhanced and select MIUI version you want and continue. Then the region selection section will come (Global, China, EEA, etc.) continue by selecting region you want. Then you will see the fastboot, recovery and incremental OTA packages, select fastboot package. It may take some time depending on fastboot package size and your bandwith. When the process is complete, copy fastboot firmware package to your PC, then extract it to a folder. You can also check out MIUI Downloader Telegram channel to get MIUI updates directly to your PC. You need to restart your device into fastboot mode. For this, turn off device and reboot into fastboot mode with the Volume Down + Power button combo. After then, connect device to the PC.
- After extracting the fastboot package, open Mi Flash Tool. Your device will appear there with its serial number, if it does not appear, restart tool with “Refresh” button. Then select the fastboot firmware folder that you extracted with the “Select” section. Flashing script with .bat extension will appear at the bottom right, and there are three options on the left side. With the “Clean All” option, üinstallation process is done and the device userdata is wiped. With “Save Userdata” option, the installation process is done, but userdata is preserved, this process is valid for stock MIUI updates. In other words, you cannot use it’s switching from custom ROM, device will not boot. And “Clean All & Lock” option installs firmware, wipes userdata and relocks bootloader. If you want to turn the device completely stock, this is the most suitable option. Select the “Flash” button with selection that suits you and start the flashing process. When finished, device will reboot.
That’s it, we unlocked bootloader, installed custom recovery, installed custom ROM, and explained how to revert to stock ROM. With this guide, you can increase performance and experience you will get from your Xiaomi device. Don’t forget to leave your views and opinions below and stay tuned for more.