The proprietary shell MIUI from Xiaomi is known for its functionality, but not all users like its design, advertising in system applications or limitations customization. If you want to get pure Android (AOSP) without unnecessary add-ons, this is possible, but it will require unlocking the bootloader, installing custom recovery and firmware via fastboot or TWRP.
In this article we will look into all stages of the transition from MIUI to stock Android: from preparing the device to choosing the appropriate firmware (GSI, LineageOS, Pixel Experience) and solving common errors. The instructions are relevant for most models Xiaomi, Redmi and POCOreleased after 2018, but on some new devices (for example, with the Snapdragon 8 Gen 3 chipset) additional steps may be required due to changes in the security policy.
We warn you right away: the process cannot be reversed without a complete data reset, and incorrect actions can lead to "briku" (inoperability) of the phone. If you are not confident in your skills, consider alternatives like disabling ads in MIUI or installing a launcher with a pure Android interface. data-i="50">I want pure Android
1. Preparing the device: what needs to be done before changing the firmware
Before you start replacing MIUI, be sure to follow these steps they will save time and prevent data loss:
- ๐ฑ Create a backup all important data (photos, contacts, messages). Use
Mi Cloud,Google Driveor local copying to your PC. Built-in MIUI tools (Settings โ About phone โ Backup) will not save the data of some applications! - ๐ Charge the phone to at least 70%. Interrupting the process due to low battery may make the device inoperable.
- ๐ป Install the necessary tools on your PC:
ADB & Fastboot(download from the official website Google or via Platform Tools)- Drivers for your model (usually installed automatically when connected to a PC)
Mi Unlock Tool(to unlock the bootloader)
- ๐ Check the model and encoding of your deviceFor example, Redmi Note 10 Pro may have versions
sweet(global) orsweetin(India). This is critical for choosing the correct firmware.
Also check whether your device supports Project Treble (required for installing GSI firmware To do this, download the application Treble Check from Google Play. If there is no support, only custom firmware compiled specifically for your model will suit you (for example, LineageOS or ArrowOS).
โ ๏ธ Attention: On devices with HyperOS (new shell from Xiaomi, which replaced MIUI) process bootloader unlocking may differ. Check the current requirements on the forum XDA Developers or in telegram chats dedicated to your model.
Make sure that the model supports custom firmware|Make a backup copy of all data|Charge the phone to 70%+|Install ADB/Fastboot and Mi Unlock Tool|Checking Project Treble support (for GSI)
-->
2. Unlocking the bootloader
By default Xiaomi locks the bootloader on all devices. To install custom firmware, you need to unlock it through the official tool. Mi Unlock Tool. The process takes from 7 to 30 days due to the company's security policy.
Unlocking instructions:
- Activate USB debugging:
- Go
Settings โ About phoneand tap onMIUI version7 times to enable developer mode. - Return to
Settings โ Advanced โ For Developersand enableUSB DebuggingiOEM Unlock.
- Go
- Bind Mi account to the device:
- In the same developer menu, find
Mi Unlock statusand link your account Xiaomi. - Connect the phone to the PC and confirm permission for debugging.
- In the same developer menu, find
- Download the utility from the official website Xiaomi (Windows only).
- Login using the same account as on your phone.
- Connect your phone to mode
fastboot(turn off the device, then pressVolume Down + Power). - Press
Unlockand wait for completion. On new devices, a wait may be required (usually 168 hours).
After successful unlocking, the phone will automatically reset to factory settings. Now you can start installing custom recovery.
โ ๏ธ Attention: If you see an error during unlocking"Couldnโt unlock"or"Device not supported", check:
- Connecting to the Internet (the utility requires online verification).
- Matching accounts on the PC and phone.
- Support for your model (some devices, for example, POCO F5 or Redmi K60may require additional steps).
What to do if Mi Unlock Tool does not see the phone?
If the utility does not recognize the device in fastboot mode, try:
1. Reinstall the drivers manually through Device Manager. (select "Android Bootloader Interface").
2. Use another USB cable (preferably original).
3. Run Mi Unlock Tool as administrator.
4. Disable the antivirus (it may block the utility).
3. Installing custom recovery (TWRP)
TWRP (Team Win Recovery Project) is an alternative recovery that allows you to install custom firmware, make backups and restore the system. Without it, changing MIUI to pure Android is impossible.
How to install TWRP:
- Download the correct version of TWRP for your model from the website twrp.me or thematic forum. Pay attention to the device encoding (for example,
vayufor POCO X3 Pro). - Go to fastboot mode (turn off the phone, then press the
Volume down + Power). - Connect the phone to the PC and check the connection with the command:
fastboot devicesThe serial number of the device should be displayed.
- Flash TWRP with the command:
fastboot flash recovery twrp-3.7.0_12-0-vayu.img(replace the file name with yours).
- Boot into TWRP with the command:
fastboot boot twrp-3.7.0_12-0-vayu.imgOr manually: After the firmware, hold down
Volume up + Powerwhen turning on.
On the first start, TWRP may ask for permission to modify the system partition - allow (swipe to the right) If the recovery asks for a password. (due to data encryption), enter the PIN code or pattern key from your phone.
| Device model | Encoding | Link to TWRP | Notes |
|---|---|---|---|
| Redmi Note 10 Pro | sweet |
twrp.me | Supports A/B markup |
| POCO X3 Pro | vayu |
twrp.me | Requires disabling AVB 2.0 |
| Xiaomi Mi 11 | venus |
twrp.me | Requires firmware with a patch for Android 12+ |
| Redmi K40 / POCO F3 | alioth |
twrp.me | Works only with firmware based on Android 11 |
If after installing TWRP the phone boots back to MIUI, and not in recovery, try disabling automatic recovery update in the developer settings (Disable MIUI automatic recovery).
4. Select firmware: AOSP, GSI or custom build
Now you need to select which firmware to install instead of MIUI. Options:
- ๐ฑ GSI (Generic System Image) - universal firmware based on pure Android, compatible with most devices on Project Treble. Examples:
- LineageOS GSI (as close as possible to stock Android).
- Pixel Experience GSI (interface like on Google Pixel).
- Phhussonโs GSI (with expanded support for functions).
- ๐ ๏ธ Custom firmware for a specific model โoptimized for your device, but require searching for a compatible version. Popular:
- LineageOS (stable, without unnecessary applications).
- ArrowOS (pure Android with minimal modifications).
- crDroid (balance between performance and functionality).
- HaventOS (for lovers of minimalism).
- ๐ Port from other devices โfor example, firmware from Google Pixel or OnePlus, adapted for your model. A risky option, it may work unstable.
Where to look for firmware:
- XDA Developers โthe main resource for custom firmware.
- Telegram chats for specific models (for example,
@RedmiNote10ProChat). - GitHub Phhusson โfor GSI firmware.
When choosing, pay attention to:
- Android version (new firmware may not support older devices).
- Markup type (A/B or A-only). Check this in the characteristics of your model.
- Presence of bugs (read reviews on the forums). data-i="197">Firmware based on Android 13+ may require
โ ๏ธ Attention: Firmware based on Android 13+ may requireDynamic PartitioniVNDK 32. If your device does not support them, select firmware based on Android 12 or lower.
GSI firmware is easier to install, but may work slower than custom builds for a specific model. If performance is important to you, look for firmware optimized for your device.
5. Installing firmware via TWRP
When the firmware is selected and downloaded, you can begin installing it. The whole procedure will take 15โ40 minutes depending on the speed of the device and size firmware.
Step-by-step guide:
- Copy the firmware to the phone:
- Connect the phone to the PC in mode
MTP(if TWRP supports) or use an OTG flash drive. - Place the firmware file (usually in format
.zip) to the root of the internal memory.
- Connect the phone to the PC in mode
- Reset (required!):
- B TWRP go to
Wipe โ Advanced Wipe. - Tick
Dalvik / ART Cache, System, Data, Cache. - Swipe to confirm (all data will be deleted!).
- B TWRP go to
- Install the firmware:
- Return to the TWRP main menu, select
Install. - Find the firmware file and confirm installation.
- If the firmware requires additional patches (for example,
Magiskfor root orDisable Force Encryption), install them immediately after the main one ZIP.
- Return to the TWRP main menu, select
- After installation, select
Wipe Cache/Dalvik. - Click
Reboot System. - Download the system image (
.imgor.xz). - In TWRP, go to
Install โ Install Image. - Select a partition
Systemand flash the image. - Install a patch to fix the boot (if required).
First boot may take up to 10โ15 minutes โ do not interrupt the process! If the system does not boot for more than 20 minutes, try repeating the installation or selecting a different firmware.
For GSI firmware the process is slightly different:
What to do if the firmware is not installed?
Typical errors and solutions:
1. Error 7 โfirmware incompatibility with the device. Check the Android model and version.
2. Error 255 โdamaged ZIP file. Download the firmware again.
3. logo - try flashing the kernel (boot.img) separately via fastboot.
4. "No OS installed" - flash the firmware again, having previously formatted the partition System.
6. Setting up the system after installation
After successfully loading pure Android, you will need to perform initial setup and solve possible problems with drivers.
First steps:
- ๐ถ Connect to Wi-Fi and log into your account Google (if the firmware supports it Google Apps).
- ๐ Update the system via
Settings โ System โ Software update(if available). - ๐ง Check the operation of basic functions:
- Calls and mobile data (configure APN manually if there is no network).
- Camera (installation GCam or patches may be required).
- Fingerprint and Face Unlock (do not work on some firmware).
- ๐ฑ Install the necessary applications:
- Magisk (if you need root).
- Open GApps (if the firmware is without Google services).
- NikGapps (alternative GApps package).
If some functions do not work (for example, NFC or Wi-Fi), look for patches on the forums. Often problems. are solved by flashing additional kernel modules or replacing vendorpartition.
To improve performance:
- Disable animations in
Settings โ System โ For developers. - Use Greenify to optimize background activity of applications.
- If the battery drains quickly, check the settings
Battery Saveror install a kernel with improved power consumption (for example, FrancoKernel).
If after installation of the firmware, the sound in the speaker disappeared, try flashing separately vendor.img from the stock MIUI via fastboot. This fixes the problem on many devices.
7. Typical errors and their solutions
Even if you follow the instructions exactly, problems may arise:
| Problem | Possible cause | Solution |
|---|---|---|
| The phone does not turn on after the firmware ("brick") | Incorrect firmware or interrupted process | Flash stock MIUI via Mi Flash Tool in mode EDL (an authorized account is required). |
| Stuck on the logo | Kernel incompatibility or lack of patches | Flash boot.img from the firmware manually or install a patch Disable DM-Verity. |
| No mobile network | No modem drivers | Flash vendor i firmware from stock MIUI or install the patch IMS. |
| Camera does not work | Missing libraries libcamera |
Install GCam with settings for your model or Flash vendor from MIUI. |
| The system constantly reboots | Conflict with Magisk or incorrect access rights | Uninstall Magisk or run Format Data in TWRP (full reset). |
If you encounter an error that is not in the table, look for a solution using its code on XDA Developers or in telegram chats, logging errors via adb logcat:
adb logcat > log.txt
Save the log and analyze it using services like Pastebin.
โ ๏ธ Attention: If, after installing the firmware, the phone no longer sees SIM cards, check whether the selected assembly supports your modem. Some devices (for example, Redmi Note 9 Pro) require firmware modem.img from stock. MIUI.
8. Alternatives: how to make MIUI look like pure Android
If the process of changing the firmware seems too complicated, consider less radical methods bringing MIUI closer to stock Android:
- ๐จ Install the launcher:
- Nova Launcher (maximum customization).
- Lawnchair (interface like on Pixel).
- Before Launcher (minimalistic design).
- โ๏ธ Disable advertising and unnecessary MIUI functions:
- T
Settings โ Applications โ Manage applicationsdisableMsa(responsible for advertising). - Remove bloatware via ADB:
adb shell pm uninstall --user 0 com.miui.analytics - Use ADB AppControl to massively disable system applications.
- T
- ๐ Install alternative applications:
- Replace
MIUI Galleryto Google Photos. - Use Files by Google instead of
MIUI files. - Install Simple Calendar or Etar instead of the standard calendar.
- Replace
- ๐ฑ Activate Android navigation gestures:
- In
Settings โ Display โ NavigationselectAndroid Gestures(if available). - Use Fluid Navigation Gestures for additional customization.
- In
These methods will not give a full-fledged pure Android, but will significantly improve the user experience without the risk of โbrickingโ the device.
If your goal is to get rid of ads and unnecessary applications, then customizing MIUI via ADB and launchers can be a sufficient solution without completely changing the firmware.
FAQ: Frequently asked questions about changing MIUI to Android
โ Is it possible to return MIUI after installing pure Android?
Yes, but for this you will need to flash the stock firmware via Mi Flash Tool v mode fastboot. All data will be erased. On some devices, you may need to unlock the bootloader again.
โ Which firmware is the most stable for everyday use?
For most devices, LineageOS or Pixel Experience are considered the most reliable. If you need maximum performance, look for firmware based on ArrowOS or crDroid with a kernel optimized for your model.
โ Will Google Services work on custom firmware?
It depends on the firmware:
- If the name contains
GApps(for example, LineageOS for microG), then the services are pre-installed. - If the firmware is without GApps, they can be additionally installed via Open GApps or NikGapps (choose option
picoornanoto save space). - On some firmware (for example GrapheneOS) Google Services are not supported in principle.
โ Why after firmware, the banking application does not work?
Most likely, protection against root access or uncertified firmware is triggered. Solutions:
- Hide root via Magisk (enable
MagiskHideand add the application to the list). - Install the module Universal SafetyNet Fix.
- If root is not needed, flash the firmware without Magisk and go through certification through
Google Play.
โ Is it possible to update custom firmware without losing data?
Yes, if the update is "incremental" (small correction of the same version). To do this:
- Download the new ZIP firmware.
- Reboot into TWRP.
- Install ZIP no wipe (simple
Installno formatting). - Clear
Dalvik/Cacheafter installation.
For major updates (for example, from Android 12 to 13) a full reset is usually required.