How to completely ban the installation of applications from unknown sources on Xiaomi Mi 9: a detailed guide

Installing apps from unknown sources on Xiaomi Mi 9 is one of the most common causes of infection of a smartphone with viruses, spyware or advertising software. APK-A file, accidental click on a fake link, or a vulnerability in a third-party installer can lead to data compromise. In this article, we will discuss all ways to block the installation of unverified applications, including hidden settings. MIUI Google Play Protect tools.

The Xiaomi Mi 9 (codenamed cepheus) feature is that the manufacturer has added additional layers of protection on top of the standard Android 9/10 features.This means that simply disabling the option in the security settings is not enough – you need to take into account the operation of MIUI services such as Security App and Mi Cloud.

Why is it important to ban installations from unknown sources?

According to Kaspersky, the 2023 year-over 60% Mobile viruses are spread through APK-files downloaded outside of Google Play, while Xiaomi is in the top-5 brands whose devices are most often targeted for attacks:

  • πŸ”“ Open architecture. MIUI, plug-in;
  • 🌍 Popularity in regions where users are actively using third-party app stores (such as APKPure or Aptoide);
  • πŸ“± Pre-installed services that may request installation permission APK (For example, Mi Browser or Mi Video).

Even if you don’t install apps from unverified sources, attackers can exploit vulnerabilities in your browser or messengers (such as phishing links in Telegram) to force the system to download and install malicious APK automatically.

πŸ“Š Have you ever installed APK From unknown sources to your Xiaomi?
Yeah, regularly.
Only 1-2 times.
No, never.
I don't know what it is.

Method 1: Disconnection through basic security settings

The most obvious method is to use the standard Android menu, but in MIUI, the path to these settings may be different from the "pure" Android.

  1. Open Settings (the gear icon on the main screen).
  2. Go to the Appendix section β†’ Application management.
  3. Click on the three dots in the top right corner and select Special Access.
  4. Slip on the item Install unknown applications.

Here you will see a list of all the apps that are allowed to install APK. By default, this list may include:

  • πŸ“ File manager (MIUI File Explorer);
  • 🌐 Browser (Mi Browser or Chrome);
  • πŸ’¬ Telegram, WhatsApp (if downloaded) APK through).

To completely disable installation, turn off the sliders in front of each application. Note: some system services (such as Package Installer) cannot be disabled - this is normal.

Is the settings "Install unknown applications" open?

Are permissions disabled for all apps on the list?

Is Google Play Protect status verified?

Is the OS updated to the latest version?

-->

Method 2: Use Google Play Protect to protect you

Google Play Protect is a built-in antivirus scanner that checks all apps installed, even if they are downloaded from third-party sources. On the Xiaomi Mi 9, it works in tandem with MIUI Security, but its settings are often ignored. To activate maximum protection:

  1. Open the Google Play Store.
  2. Slip on the profile avatar in the upper right corner.
  3. Select Play Protect β†’ Settings (cog icon).
  4. Turn on the options: πŸ” Scan the device for threats; πŸ›‘οΈ Improved security controls (if available).

Play Protect will block the installation of suspicious APKs before they are launched, but this does not replace disabling unknown sources, since the scanner can miss fresh threats that have not yet been added to Google’s database.

πŸ’‘

If Play Protect detects a threat but cannot remove it, restart your phone in Safe Mode (hold the power button β†’ Safe Mode) and manually uninstall the suspicious app.

Method 3: Blocking through MIUI Security (built-in antivirus)

Xiaomi has integrated its own security tool, the Security app, into the firmware, which not only scans the system, but can also restrict the installation of APKs.

  1. Open the Security app (if it isn’t on the home screen, search through search).
  2. Go to the Security tab (or Security in English).
  3. Slip on Settings (cog in the corner) β†’ Application privileges.
  4. Find the Install Unknown Applications and disable it.

In some versions of MIUI (e.g. MIUI 12.5 and later), this item may be called Special Permissions β†’ Install Unknown Apps. If you do not have an option, update the Security app via Google Play.

⚠️ Note: After disabling this option, some system updates (such as Mi Camera or Mi Video patches) may be delayed.This is normal – Xiaomi first checks them through official channels.

Method 4: Edit build.prop (for power users)

If you're willing to take drastic measures, you can edit the build.prop system file that manages Android permissions, a method that requires root rights and can lead to unstable device performance if executed incorrectly.

Instructions:

  1. Install a file manager with root support (such as Root Explorer).
  2. Go to /system/build.prop.
  3. Find ro.secure=1 (if not, add it to the end of the file).
  4. Save the changes and restart the device.
  5. Lock down the installers. APK: 🚫 Remove or disable applications like APK Installer or Package Installer; πŸ”§ Use it. ADB, To ban installation globally: adb shell settings put global install_non_market_apps 0

If you are transferring your phone to another person (such as a child or colleague), create a separate user profile with limited rights:

  1. Go to Settings β†’ System β†’ Additional β†’ Multiple users.
  2. Create a new user and assign them a limited profile role.
  3. In the profile settings, disable access to Security Settings and Application Installation.

If you use custom firmware (for example, LineageOS), these settings may not be available at all – in this case, you need to configure the lock via ADB or build.prop.

How to check if there is malware on the phone?
Follow the following steps: Open Settings β†’ Apps and sort the list by installation date. Unknown apps with suspicious names (e.g. com.system.update) are a sign of infection. Run a scan in Google Play Protect and MIUI Security. Check traffic flow in Settings β†’ SIM-maps and mobile networks β†’ Traffic usage: Malware often consumes data in the background; install an antivirus (such as Malwarebytes or Bitdefender) and scan the system; if suspicious software is detected, do not manually remove it, as some viruses disguise themselves as system processes. Better perform reset to factory settings (Settings) β†’ The phone. β†’ Resetting settings).
Can I block APK installation via Google Family Link?
Google Family Link allows you to restrict the installation of applications, but does not block unknown sources completely: πŸ“± Set a limit on the installation of applications by age rating; πŸ” Receive notifications of attempts to install new programs; 🚫 Block access to Google Play and third-party stores, however, to completely block APK You still need to use the methods described above.
What if updates to system applications have stopped being installed after blocking?
Some Xiaomi apps (such as Mi Browser or Mi Video) are updated through its own App Store service, which may require permission to install APK. If updates stop coming: Temporarily allow the installation of unknown sources for the App Store app (Settings β†’ Apps β†’ Special Access β†’ Install Unknown Apps). Update the desired applications. Turn off permission again. Alternatively, update the apps via Google Play (if available there) or manually download the official APK from app.mi.com.