Xiaomi, Redmi and Poco smartphone owners regularly encounter one of the most annoying features of MIUI firmware β intrusive ads that appear even on a locked screen. The problem is compounded by the fact that standard ways to turn it off (via Mi Account settings) often donβt work due to regional restrictions or device locks. In this article, weβll look at 5 proven methods to help remove ads on any Xiaomi device β from the budget Redmi Note 12 to the flagship Mi 14 Ultra β even if the phone is locked with a password, pattern lock or account.
Itβs important to understand that MIUI ads are built into system applications (com.miui.systemAdSolution, com.xiaomi.midrop) and services (msa, analytics). Simply disabling Personalized Recommendations in settings often fails β banner ads continue to appear in Security, Weather, Themes, and even on the lock screen. Below youβll find solutions of varying degrees of complexity, from basic settings to manually editing configuration files via ADB.
1. Disable advertising through hidden MIUI settings (no root)
The first method is suitable for devices that have access to the main settings menu, but the standard options to disable advertising do not work. In MIUI 14/15 (current for models 2023-2026), some ad modules can be deactivated through hidden settings:
- Go to Settings β About Phone and 7 times click on the MIUI version to activate Developer Mode.
- Go back to the main settings menu and open a new section for developers.
- Find the USB Debugging option and turn it on. Confirm permission if you request it.
- Connect your phone to your PC and execute the command in ADB (instructions below in Section 3).
If you donβt have access to settings because of locking, skip this step and go to the method from Fastboot or Recovery.
List of apps that most often show ads on a locked screen:
- π± Launcher (com.miui.home) - banners at the bottom of the screen.
- π Lock screen (com.android.keyguard) β Advertising when unlocking.
- π¦οΈ Weather (com.miui.weather2) β banner-widget.
- π‘οΈ Security (com.miui.securitycenter) β Advertising in notices.
2. Reset advertising ID through Engineering Mode (for advanced users)
One little-known way to reduce the amount of ads displayed is to reset the Advertising ID that Xiaomi uses to target banners, a method that does not require root rights, but requires the input of an engineering code:
- Open the Phone app and type the combination: ##6484## (or #64663## for new models).
- In the menu that appears, select Advertising ID (or Advertising ID).
- Press Reset Advertising ID and confirm the action.
- Reboot the device β this will lead to resetting targeted ads.
Limitation: It doesn't remove ads completely, it just resets personalized settings, and in 1-2 weeks, banners can reappear again, but in smaller numbers.
What to do if the engineering menu is not opened?
β οΈ Warning: Do not change other options in the engineering menu unless you are sure of their purpose. Incorrect settings can lead to network loss or sensor failure.
3. Removal of ads via ADB (without unlocking the bootloader)
If your phone is locked, but you have access to debugging USB (For example, through Fastboot or Recovery mode, you can remove advertising packages using the ADB-This method works on all Xiaomi devices with MIUI 12β15, including 2026 models (Redmi Note 13 Pro)+, Poco X6 Pro and others.).
Step-by-step:
- Install ADB and Fastboot Tools on PC.
- Connect your phone to your computer and confirm debugging permission (if the screen is unlocked). If the device is locked, turn it into Fastboot mode (press Power + Vol Down).
- Open the command line (Windows) or terminal (macOS/Linux) and type:
adb devices(Your device should appear on the list.)
adb shell pm uninstall --user 0 com.miui.systemAdSolution
adb shell pm uninstall --user 0 com.xiaomi.midrop
adb shell pm uninstall --user 0 com.miui.analytics
adb shell pm disable-user --user 0 com.miui.bugreport
adb shell pm disable-user --user 0 com.miui.hybridThese commands remove the main MIUI ad modules. If you want to return them back, replace uninstall with install-existing.
Install Xiaomi drivers on PC|
Enable debugging over USB in the developer settings |
Connect the phone with the original cable |
Check the visibility of the device by the team `adb devices`|-->
For locked-screen devices: If USB debugging was enabled before locking, you can try to execute blind-mode commands. More on this in the next section.
4. editing the hosts file to block ad servers
If previous methods failed, you can block Xiaomiβs ad servers at the system level by editing the hosts file.This requires root rights or access to Recovery with ADB Sideload support.
List of servers that need to be blocked:
| domain | Appointment | Note |
|---|---|---|
| sdkconfig.ad.xiaomi.com | The main server of targeted advertising | Blocks banners in system applications |
| tracker.ai.xiaomi.com | Collecting user analytics | Reduces the number of personalized ads |
| ad.mi.com | Displaying ads in MIUI | Responsible for banners on the lock screen |
| data.mistat.xiaomi.com | Usage statistics | It does not directly affect advertising, but reduces targeting. |
How to edit hosts:
- Download a modified hosts file (for example, from here) or create your own.
- Connect your phone to your PC and do:
adb push hosts /sdcard/
adb shell su -c "mount -o rw,remount /system"
adb shell su -c "cp /sdcard/hosts /system/etc/hosts"
adb shell su -c "chmod 644 /system/etc/hosts"β οΈ Attention: Incorrect editing of the hosts file can lead to loss of Internet access.Before making changes, make a backup of the original file with the command: adb pull /system/etc/hosts hosts_backup
5. Complete removal MIUI-service TWRP (loader)
If your Xiaomi device has an unlocked bootloader and custom Recovery (TWRP) installed, you can remove ad modules at the system file level, a method that offers a 100% guarantee of removing ads, but requires technical skills.
Step-by-step:
- Download. TWRP For your model (for example, for Redmi Note) 12 Pro. twrp-3.7.0_12-vayu.img).
- Download to TWRP (press Power + Vol Up when you turn on).
- Connect your phone to your PC and do:
adb shell
mount /system
rm -rf /system/priv-app/SystemAdSolution
rm -rf /system/app/Analytics
rm -rf /system/app/MiDrop
rm -rf /system/app/HybridPlatform
rm -rf /system/app/MiuiDaemonAfter removal:
- π Reset the device.
- π± Check the absence of advertising in Settings β Applications (SystemAdSolution and Analytics must disappear).
- π If the screen is locked, reset the pattern lock through TWRP β Advanced β File Manager (delete the file) /data/system/gesture.key).
π‘
If after removing system applications, the phone stopped booting, restore them through a backup in the TWRP or re-follow MIUI via Fastboot with option clean_all.
6.Alternative firmware: switching to AOSP or LineageOS
If none of the above methods worked, the radical solution is to install custom firmware based on AOSP (for example, LineageOS, Pixel Experience or ArrowOS), these firmware are completely devoid of advertising and pre-installed Xiaomi services, but have their own nuances:
Pros:
- β Total lack of advertising and surveillance.
- β Itβs a smoother experience (especially on older models like the Redmi Note 9 Pro).
- β Regular security updates.
Cons:
- β Loss of function MIUI (Second Space, Game Turbo, and the Game Turbo).
- β Possible bugs with camera or sensors (on some models).
- β Requires an unlocked bootloader and experience with Fastboot.
How to install custom firmware:
- Unlock the bootloader via the Mi Unlock Tool (can take up to 7 days to wait).
- Install TWRP for your model.
- Download firmware (for example, LineageOS from lineageos.org).
- Fly through TWRP with full Wipe (Wipe β Format Data).
π‘
Installing custom firmware will void Xiaomi's warranty. Before the procedure, save all data, as it will be erased.