Backlight vs pixel values
First and most importantly, if at all possible adjust the display backlight, rather than using software correction of pixel values. If you dim the backlight you still get full or near-full dynamic range, giving you a clearer, "deeper" image that tends to be more readable.
Software adjustment can't make the blacks darker, it just makes white greyer and reduces contrast. So instead of using pixel values from 0-255 it might use from 0-180 for example. Everything looks flatter.
A tool like Redshift can be useful for changing colour balance, but as much as possible you should try to change brightness with backlight adjustment.
Last I checked, most displays unfortunately do(did?) not implement backlight control from software. There's a standard for it, DDC/CI but adoption has been limited. Try the ddccontrol tool with your monitor and see if you have any luck.
I've only seen it in very high end displays intended for calibrated photo and video work ... and even many of those use a USB connection and custom USB HID based driver instead of the DDC/CI standard. I'm pretty outdated though, and the linked article claims that basic options like brightness and contrast are widely supported now.
Fake brightness controls on cheap displays
Some cheap displays don't support backlight control at all. The brightness controls on the display just adjust the pixel values on the LCD, just like software control does. Do not use these controls if you have such a monitor; it's usually better to do the correction in software, certainly no worse.
Doesn't go dim enough?
All too many displays do have backlight control, but minimum brightness is still eye-searing. They can sometimes be modified, but otherwise your best bet is setting them to minimum backlight brightness and then living with changing pixel values to get them even dimmer.
It really annoys me that displays have such a limited backlight intensity range, often artifically and arbitrarily limited, starting at eye-searing to "the power of a million suns". I look for dim backlights when I'm speccing out displays to buy.
On a laptop, the backlight is usually controlled by software. Yay!
(If your laptop is still old enough to use APM control instead of ACPI or custom drivers, get off my lawn).
The details are somewhat driver and software specific, but your laptop should offer convenient Fn keys that make it easy, and the OS should have a simple display brightness slider. The
xbacklight utility offers a convenient command line control for this, though on my system it doesn't seem to like to go below 1% brightness and goes straight to black.
I twiddle the driver controls because my T460 is very bright - wonderful during the day, but horrible at night. The minimum brightness step offered by the fn key adjustments is still way too bright, but the driver provides much finer grained control. xbacklight only lets me get down to brighness 8/255 and I'd like So I tell it to run at 4/255 brightness:
echo 4 | sudo tee -a /sys/class/backlight/intel_backlight/brightness
This works on a Lenovo T460 with Intel graphics, but other drivers and hardware may have different entries under
/sys/class/backlight with different range limits etc.
The arch wiki has some useful info.
When you lower brightness you might want to increase contrast in software a bit, especially if working on text. It'll cost you image quality, but gain you readability at low brightness. The
xgamma utility will let you do that, e.g.
xgamma -gamma 0.8
Someone want to patch Redshift with brightness controls?
So, you know what'd be cool?
If Redshift could fade display brightness based on an ambient light sensor and/or time of day, via the same xrandr controls used by xbacklight.