ls /sys/class/backlight/This will display available interfaces like intel_backlight, acpi_video0, or similar.
For Intel backlight (where 0 means turn off):
sudo tee /sys/class/backlight/intel_backlight/brightness <<< 0upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep percentagecat /sys/class/power_supply/BAT0/capacitypowerprofilesctl getUse the GUI to turn it on or off.
If you're unsure which display manager is in use, check with:
ps aux | grep dmFor LightDM:
sudo service lightdm stop
sudo service lightdm startOr for GDM3:
sudo service gdm3 stop
sudo service gdm3 startNote: When your GUI is turned off (after stopping the display manager), you can still access the terminal:
- Press
Ctrl+Alt+F2throughCtrl+Alt+F6to switch to a virtual console- Log in with your username and password
- Restart the GUI with:
sudo service lightdm startorsudo service gdm3 start(depending on your system)