How to Block Internet Access for Specific Android Apps

https://www.profitableratecpm.com/f4ffsdxe?key=39b1ebce72f3758345b2155c98e6709c

About ten years ago, I was daily driving a custom Android ROM called CynanogenMod. In its settings app, there were built-in switches to cut off Internet access from any app. Unfortunately, native Android still doesn’t have this feature, even in the latest version 16 update. Let me show you a workaround and why you might want to use it.

Why should you block Internet access for applications separately

First, not all applications need Internet access. Others don’t need background access because they mainly use it to call home with your personal data. Blocking internet access for these apps makes them more privacy friendly.

Many Android apps tend to rely on ads to generate revenue. Some display tiny banners (which I don’t mind), but others display full-screen advertising walls every few minutes, which gets annoying very quickly. Often, these apps don’t even need an Internet connection and only access the Internet to serve ads. If an app or game can work offline for you, cutting off the internet also removes ads.

A hand holding a phone with a set data limit displayed. Credit:

Lucas Gouveia / How to Geek | Tanveer Anjum Towsif / Shutterstock

As I said, Android apps tend to run in the background to display notifications or return user data, which does two things: they consume battery and burn data, depending on background activity levels. Taking these apps offline will also save battery and data (useful if you have a limited plan).

Android still doesn’t support it natively, so we need an app

Stock Android doesn’t offer native functionality to block internet access for specific apps, and neither do OEM Android skins (as far as I know). So we will need a third party app for this to work. NetGuard is a free, open source application from developer FairMail. It does not require root access and therefore works on any Android device. It lets you turn off Wi-Fi and data separately for apps. So if you want to save data, you can enable cellular for critical apps only and have the rest use Wi-Fi only. You can create a lock mode with exceptions and even record an app’s attempts to connect to the Internet.

Netguard screenshots.

NetGuard uses a local VPN configuration to filter traffic, so it does not need system-level access that requires root. So if you want to use another VPN service at the same time, it won’t work with NetGuard because you can only channel traffic through one VPN at a time.

How to configure NetGuard and block Internet access

Setting up NetGuard is quite simple. Start by installing the app from the Google Play Store or F-Droid. Tap the big switch at the top of the app. On first launch, the application will ask for permission to use the local VPN service. Grant it.

By default, Android manages how an app runs in the background to preserve battery life, which means the system may randomly delete an installed app. To keep the NetGuard app running in the background, we will exclude NetGuard from Android’s battery optimization measures. The app will ask you to do this, but if you missed it, just go to the app settings and tap “Don’t allow” on the background battery optimization feature.

Once you’re on the dashboard, you’ll see a list of all installed apps with Wi-Fi and cellular icons next to each one. NetGuard works on a simple color-coded system: a green Wi-Fi or cellular icon means the app can access Wi-Fi or data, and a red Wi-Fi or cellular icon blocks that app’s access to that connection.

All you have to do is tap the corresponding icon next to the app in the list to trigger the filter. The setup is modular, so you can turn off Wi-Fi, data, or both for any given app.

If you have a long list of apps and want to block all apps at once, you don’t need to scroll through the entire list and press buttons on each app to manage Internet access. This is what Lockdown Traffic mode is for. In Lockdown Traffic mode, NetGuard blocks Internet traffic from all applications installed on the phone. Tap the three dots in the corner, then check “Lockdown Traffic” to enable this mode.

In most use cases, you don’t want to disable Internet access for all applications. NetGuard also allows you to allow selected applications to bypass traffic blocking restrictions. Tap an app name to view an additional set of filters for that app. Here you can tap “Allow in Lockdown Mode” to add it to the allowlist. You can add multiple apps to the allow list and keep the lock mode enabled persistently.

NetGuard also lets you create granular filters like this to target an application’s background activity. Once you’ve turned off an app’s data or Wi-Fi with hotkeys, tap its name to view additional filters. Here you can choose how access to the app is restricted when the screen is on. You can allow Wi-Fi, data, or both when the screen is off, and NetGuard will automatically block it when you’re not actively using your phone.

Some bonus tips

I mentioned earlier that you can cut off an app’s Internet access to get rid of spam ads or notifications, and while this works for most apps, it’s not a foolproof solution. This may not work for all apps because Google designed Google Play Services to display these ads on top of the app. So even if you block this app’s Internet access, you can still see ads served by Google Play Services.

The same goes for incoming notifications and messages received by Google Play Services. Android’s built-in download manager app gets Internet access by default, and since NetGuard can’t filter system apps, downloads will also go through, even in NetGuard’s Lockdown Traffic mode.

Added NetGuard to the Quick Settings panel.

Instead of opening and closing the NetGuard application every time you need to enable or revoke Internet access, you can add it to the quick settings panel in the notification area. Simply pull down the quick settings pane, tap the edit icon and add the Netguard toggle to the list of toggles.

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button