Android Q: How to toggle system-wide dark mode using ADB


Few hours back Google released Android Q, the next major update with several new features for Pixel phones, but the first beta doesn’t bring system-wide Dark mode as rumored.  ‘Device Theme’ and ‘Night Mode’ settings from Android Pie have been removed in Android Q. Dark mode is enabled automatically for some, if ‘Night mode’ is enabled in Android Pie before updating to Android Q. Battery saver in Android Q turns system apps dark, but this disables important notifcations, haptic feedback and several things. However, you can enable, disable or turn auto dark mode with simple ADB code.

Requirements

How to enable dark mode

  1. Connect the Pixel to your PC / Mac, open command prompt / terminal window in the same directory where ADB binary is stored
  2. Enable Dark Mode: adb shell settings put secure ui_night_mode 2     Disable Dark Mode: adb shell settings put secure ui_night_mode 1
    Auto Dark Mode: adb shell settings put secure ui_night_mode 0
  3. If you’re using Windows, you need to add .\ before the command. If you’re using macOS or Linux, then add ./ before the command.
  4. Reboot your Pixel to get the system-wide dark mode

Dark mode will remain until you factory reset the phone. Hope future Android Q beta updates will bring back ‘dark mode’ toggle.

Via


Author: Srivatsan Sridhar

Srivatsan Sridhar is a Mobile Technology Enthusiast who is passionate about Mobile phones and Mobile apps. He uses the phones he reviews as his main phone. You can follow him on Twitter and Instagram