Recently Gnome came up with a new feature of Night Light. It is really helpful.
It feels too time-consuming that I need to go to settings (and then display) and activate it each time. Is there any terminal command that can simply turn on the night light feature?
Manual and/or sunrise to sunset option aren't really helpful as even I don't know when I will be needing that particular feature to turn on or off.
I tried to google but, found nothing related to command.
Might not matter, but just in case, I am using Kali Linux.
This is the feature I am talking about.

Asked
Active
Viewed 1.2k times
12
don_crissti
- 79,330
- 30
- 216
- 245
Ugnes
- 259
- 3
- 6
- 13
-
2You mean gnome, right? This is a gnome feature, not a kernel feature. – Zip Oct 23 '17 at 22:10
-
Yes! That's right. – Ugnes Oct 23 '17 at 22:11
-
@Zip if this is Gnome feature then why I didnt found it in Ubuntu ? – Infinite Loops Nov 25 '18 at 07:40
-
@InfiniteLoops Which version fo Ubuntu are you using? – Ugnes Nov 26 '18 at 14:11
-
Another way (cron+redshift) described here: https://askubuntu.com/questions/991832/redshift-configuration-how-to-set-fixed-transition-hours – Anatolii Kurotych Dec 23 '20 at 17:22
1 Answers
14
Yes, you can turn it on with
gsettings set org.gnome.settings-daemon.plugins.color night-light-enabled true
or
dconf write /org/gnome/settings-daemon/plugins/color/night-light-enabled true
Same commands with false instead of true will turn it off.
If you list the keys under the org.gnome.settings-daemon.plugins.color schema you'll see that you can also configure the schedule (auto: on/off, manual: from/to) as well as the night light temperature. A very convenient way to set the latter is via the night light slider extension.
don_crissti
- 79,330
- 30
- 216
- 245
-
The first command is now giving the error: *GLib-GIO-Message: Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications.* The second one is working fine. **What could be the reason?** – Ugnes Nov 09 '17 at 19:38
-
1@Ugnes - google for that error and you'll see there are plenty of possible causes. FWIW I can't reproduce it... works fine here. – don_crissti Nov 09 '17 at 21:14
-
@don_crissti I am able to execute the commands that you mentioned as follows: `$ gsettings set org.gnome.settings-daemon.plugins.color night-light-enabled true; $ gsettings get org.gnome.settings-daemon.plugins.color night-light-enabled; true`. But nothing happens. I opened dconf-editor GUI, and the value doesn't change there, even though using `gsettings get` outputs changed value. What should be done? – Porcupine Feb 07 '20 at 20:10