Privacy Flip
2.4.0 · GitHub
More about this app
Manage your device privacy based on lock/unlock state
PrivacyFlip
Automatic lock/unlock privacy control for Android devices ๐๐ฑโจ
PrivacyFlip automatically manages your Android device's privacy features based on lock/unlock state. When you lock your device, it can disable Wi-Fi, Bluetooth, mobile data, location services, NFC, and even camera/microphone sensors. When you unlock, it intelligently restores the features you want back on.
Works with Sui, Root, Dhizuku or Shizuku - Choose your preferred privilege method!
๐ธ Screenshots
๐ Features
Automatic Privacy Control
- Lock Detection: Disables privacy features when the screen locks, after your lock delay (camera and microphone at once)
- Unlock Detection: With a PIN, pattern or password, waits until you unlock it. With no secure lock, turning the screen on counts as unlocking
- Smart Restoration: Configurable feature re-enabling on unlock. With Dhizuku, some features cannot follow this setting (see Option 3)
Privacy Features Controlled
- ๐ถ Wi-Fi - Disable/enable wireless connectivity
- ๐ฑ Bluetooth - Control Bluetooth radio
- ๐ก Mobile data - Manage cellular data connection
- ๐ Location services - Control GPS and location tracking
- ๐ณ NFC - Control Near Field Communication sensor
- ๐ท Camera - Disable/enable camera sensor privacy (Android 12+)
- ๐ค Microphone - Disable/enable microphone sensor privacy (Android 12+)
- โ๏ธ Airplane Mode - Enable airplane mode on lock (opt-in, disables all radios)
- ๐ Battery Saver - Enable battery saver mode on lock (opt-in)
Advanced Features
Smart Disable Options:
- "Only if unused/not connected" - Don't disable WiFi, Bluetooth, or Location if actively in use, or Mobile Data while media is playing. The microphone is not disabled during a phone or VoIP call. While a Wi-Fi hotspot is on, Wi-Fi, mobile data and Airplane Mode are always left alone
- "Only if not already enabled" - Prevent connection resets by not re-enabling features that are already on
- "Only if Privacy Flip turned it on" - On unlock, turn Airplane Mode or Battery Saver off only if Privacy Flip turned it on
App Exemptions - If an exempt app is in front when the phone locks, nothing is disabled. Unlock always runs. Needs Usage Access
NFC Auto-Retry - Opt-in: if a payment or wallet app turns NFC back on right after Privacy Flip turns it off, retry disabling it
Keep Off While Locked - Opt-in: if Wi-Fi, Bluetooth, mobile data, location or NFC is switched back on before you unlock (for example from Quick Settings), or Airplane Mode or Battery Saver is switched off, Privacy Flip runs its lock actions again, with the same "only if" rules; camera and microphone cannot change while locked. It puts back only what Privacy Flip itself turned off, at most 5 times per lock, and only while the background service runs
Accessibility Service - Experimental, opt-in: an extra lock and unlock signal from the lock screen window (requires Accessibility permission). It does not make camera and microphone work with an instant power-button lock: Android refuses that once the phone is locked
Quick Settings tile and home screen widget - Turn protection on and off. Turning it off needs an unlocked phone
Advanced Detection - Multi-tier Bluetooth connection detection prevents unwanted headphone disconnects
Customizable Timing
- Lock Delay: 0-60 seconds (granular), 2 minutes, or 5 minutes before privacy actions trigger
- Unlock Delay: 0-60 seconds (granular), 2 minutes, or 5 minutes before features are restored
- Instant Mode: Set delays to 0 for immediate action
- Note: Camera and microphone ignore custom delays and trigger immediately, due to Android limitations
๐ฑ Requirements
Minimum: Android 8.0+ (API level 26) Camera/Microphone Features: Android 12+ (API level 31)
Choose your privilege method:
Option 1: Shizuku (No root required!)
- Shizuku app installed and running
- ADB privileges via USB debugging or wireless ADB
- No root required - works with ADB-level permissions
Option 2: Root Access (Recommended for rooted devices)
- Root access via Magisk, SuperSU, or similar
- Best performance with UID 0 privileges
Option 3: Dhizuku (Device Owner method, 5 of 9 features)
- Device Owner status. Android refuses to set a Device Owner on a device that already has a second user, such as a work profile
- No root required, no ADB needed after initial setup
- Persistent privileges - survives reboots
- Works for, and each needs its own Android version: Camera and Microphone (Android 12+), Bluetooth (Android 9+), Location (Android 11+), NFC (Android 15+). Below Android 9 a Dhizuku setup can switch nothing at all.
- Cannot do: WiFi, Mobile Data, Airplane Mode, Battery Saver. Dhizuku shares Device Owner rights, and Android gives a Device Owner no way to switch those. Use Root or Shizuku for them.
- At unlock: NFC, camera and microphone always come back on. Bluetooth never does: turn it on yourself
Option 4: Sui (Best of both worlds)
- Rooted device with Magisk installed
- Sui Magisk module installed
- Best user experience - no permission prompts, automatic startup
Privilege Detection Priority
- Sui - Magisk module providing Shizuku API with root (best UX)
- Root - Traditional root access via Magisk/SuperSU
- Dhizuku - Device Owner method (no root or ADB needed after setup)
- Shizuku - ADB privileges via Shizuku app
๐ค Contributing
Help make this app better. No contribution is too small!
How to Contribute
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
All contributions are valued and appreciated!
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ Support Development
PrivacyFlip protects your privacy. You can protect its future!
Late nights for brighter days
Created by Doru Moraru
How Shizuku is used
Can toggle WiFi, Bluetooth, data, NFC, location, camera, mic, airplane mode and battery saver via `Shizuku shell commands`.
This is an AI-assisted analysis of Shizuku-related usages in the app's public source code. It is best effort, so it may not catch every single usage.
How this app uses Shizuku
Shizuku is used to switch privacy sensitive features off on lock and back on on unlock and to read back their state.
- Switch wireless radios: turn WiFi, Bluetooth and mobile data off on lock and back on on unlock with the
svc wifi,svc bluetoothandsvc datashell commands through Shizuku, with state checked withdumpsys wifi,dumpsys bluetooth_manageranddumpsys telephony.registry. - Switch NFC: turn NFC off on lock and back on on unlock with the
svc nfcandcmd nfcshell commands through Shizuku, and on newer Android with a direct NFC service call through Shizuku, with state checked withdumpsys nfc. - Control location services: turn location providers off and on with the
settings put secureshell commands through Shizuku, with state checked withsettings get secureanddumpsys location. - Block camera and microphone: block and unblock camera and microphone access with the
cmd sensor_privacyshell command through Shizuku, with state checked withdumpsys sensor_privacy. - Toggle airplane mode: turn airplane mode on and off with the
cmd connectivity airplane-modeshell command through Shizuku, with state checked withsettings get global airplane_mode_on. - Toggle battery saver: turn battery saver on and off with the
cmd power set-modeandsettings put global low_powershell commands through Shizuku, with state checked withdumpsys power. - Skip features in use: optionally leave WiFi, hotspot and location alone when they look actively used, checked with the
dumpsys connectivity,dumpsys tetheringanddumpsys appopsshell commands through Shizuku.
Android APIs or commands used
svc wifi enablesvc wifi disablesvc bluetooth enablesvc bluetooth disablesvc data enablesvc data disablesvc nfc enablesvc nfc disablecmd nfc enablecmd nfc disablecmd nfc enable-nfccmd nfc disable-nfc '[persist]'android.nfc.INfcAdapter.enableandroid.nfc.INfcAdapter.disablecmd sensor_privacy enable 0 cameracmd sensor_privacy disable 0 cameracmd sensor_privacy enable 0 microphonecmd sensor_privacy disable 0 microphonecmd connectivity airplane-mode enablecmd connectivity airplane-mode disablecmd power set-modesettings put secure location_modesettings put secure location_providers_allowedsettings get secure location_modesettings get secure location_providers_allowedsettings put global airplane_mode_onsettings get global airplane_mode_onsettings put global low_powersettings get global low_powersettings get global wifi_onsettings get global bluetooth_onsettings get global mobile_dataam broadcast -a android.intent.action.AIRPLANE_MODEdumpsys wifidumpsys bluetooth_managerdumpsys telephony.registrydumpsys locationdumpsys nfcdumpsys sensor_privacydumpsys powerdumpsys connectivitydumpsys tetheringdumpsys appops
Notable details
Camera and microphone blocking uses the system sensor privacy switch and is only available on Android 12 and later, so those two options do nothing on older versions. On newer Android, NFC switching prefers a direct system NFC call through Shizuku and falls back to shell commands if the service refuses it.
Changelog
What's new for version 2.4.0
- Android 8.0 or newer is now required
- The tile and widget now need an unlocked phone to turn protection off
- Turning protection off while locked no longer leaves radios off after unlock
- Root: "Check Again" now appears if you refused Magisk the first time
- Lock detection resumes after a Shizuku restart, even with protection off
- Debug output shows when a radio is turned back on while locked
- "Only if not manually set" is renamed "Only if Privacy Flip turned it on"
Permissions
17 permissions requested
Sources
2 sources
Sources
2 sources

