package icon

USB Debug Guard

Turn the screen off during long USB debugging sessions while keeping ADB alive
New in version 0.1.6
The F-Droid build no longer asks for network access: it has no update check, so it never needed the INTERNET permission. Guard behavior is unchanged.
USB Debug Guard is a root-only tool for long USB debugging sessions. It protects the display while keeping ADB reachable, then restores the previous display settings when protection stops.

Features

  • Detects USB data connections and ADB state through Android system APIs, without routine Root polling.

  • Turns the screen off while keeping ADB reachable, or keeps it awake at minimum brightness for devices that lose ADB when the display sleeps.

  • Saves and restores the previous display settings.

  • Can lock the device after USB disconnects.

  • Runs only after you enable its foreground service.

  • Stops automatic Root work after a denial, timeout, exception, or process cleanup failure, preventing an endless su retry loop.

  • English and Simplified Chinese.



Requirements

  • A working Root manager such as Magisk or KernelSU, able to run Android settings and input commands.

  • A USB data connection. A charge-only cable or charger does not start protection.



Root behavior varies between devices, OEM firmware, and Root managers. Test the app on a non-critical device before relying on it for unattended sessions.

Versions

Although APK downloads are available below to give you the choice, you should be aware that by installing that way you will not receive update notifications and it's a less secure way to download. We recommend that you install the F-Droid client and use that.

Download F-Droid
  • Version 0.1.6 (7) suggested Added on Oct 29, 2026

    arm64-v8a armeabi-v7a x86 x86_64

    This version requires Android 8.0 or newer.

    It is built and signed by the original developer, and guaranteed to correspond to this source tarball.

    Permissions
    • run foreground service
      Allows the app to make use of foreground services.
    • run foreground service with the type "specialUse"
      Allows the app to make use of foreground services with the type "specialUse"
    • show notifications
      Allows the app to show notifications
    • run at startup
      Allows the app to have itself started as soon as the system has finished booting. This can make it take longer to start the phone and allow the app to slow down the overall phone by always running.
    • prevent phone from sleeping
      Allows the app to prevent the phone from going to sleep.
    • io.github.nongfsq.usbdebugguard.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION

    Download APK 1 MiB PGP Signature | Build Log

  • New in version 0.1.5
    Much smaller download: the APK drops from about 12.6 MB to 1.1 MB. Guard behavior and Root safety are unchanged.
  • Version 0.1.5 (6) - Added on Oct 27, 2026

    arm64-v8a armeabi-v7a x86 x86_64

    This version requires Android 8.0 or newer.

    It is built and signed by the original developer, and guaranteed to correspond to this source tarball.

    Permissions
    • run foreground service
      Allows the app to make use of foreground services.
    • run foreground service with the type "specialUse"
      Allows the app to make use of foreground services with the type "specialUse"
    • have full network access
      Allows the app to create network sockets and use custom network protocols. The browser and other applications provide means to send data to the internet, so this permission is not required to send data to the internet.
    • show notifications
      Allows the app to show notifications
    • run at startup
      Allows the app to have itself started as soon as the system has finished booting. This can make it take longer to start the phone and allow the app to slow down the overall phone by always running.
    • prevent phone from sleeping
      Allows the app to prevent the phone from going to sleep.
    • io.github.nongfsq.usbdebugguard.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION

    Download APK 1 MiB PGP Signature | Build Log