The dark reader extension can force a light theme as well. It would be more properly named the “respect my theme preferences for real” extension. It is a bit annoying that it is necessary.
Yeah their actual point is about contrast ratio, which makes the headline a bit disingenuous.
Ironically they end by saying they'll use an invert filter as a workaround, while for those who prefer dark mode if doing the same on the author's own stark white bg/black text site (such as Vivaldi's 'Invert Mode') will produce the very contrast ratio in dark they're complaining about :p
I think the more specific argument is to avoid sudden changes in brightness.
Neither dark mode nor light mode is the one true “main” option. We had dark mode for a long time with terminals. Then light mode a long time with word processors and the web and OSes. And now we kinda have both.
/* Dark mode */
@media (prefers-color-scheme: dark) {
...
}
The issue with both dark and light modes is so many designers seem to have jumped onto the idea that colour schemes have to be either bright white or darkest black.
I'd much rather see colours that are 'slightly darker' at night and 'slightly lighter' in the daytime. For one thing there are still so many websites with no colour schemes setup at all so if you avoid going to extremes it minimises the contrast difference.
The other issue is many sites don't use that CSS media query at the minimum for auto setting the theme. They instead use a Javascript approach that often involves local storage/cookies even if no choice is made, which doesn't work if those are blocked and/or Javascript disabled. In such cases the default theme is forced.
The optimal approach is applying the appropriate `prefers-color-scheme` using CSS alone, while additionally allowing a theme override using JS/storage. Fewer do this though, even though it wouldn't require any cookies and thus no consent dialog.
The worst are sites that only have theme switching gated behind registration.
The truth is that you need to do device detection, so the @prefers CSS stuff, then you need to have a toggle to over-ride things. Then you need some javascript to store the preference in local storage.
On page load you get your javascript to check the mode and check the override to add a class to the whole page. It is this class that implements the desired light or dark theme.
Fighting against you is what the browser is doing. You can put a meta tag in to force it to respect one theme or the other so it does not go freestyling.
People that have a page permanently set to light mode (or dark mode) have put in the meta tag but they haven't done the extra work to implement some meaningful choice.
In summary, there is auto, where the browser does its best, one mode enforced with a meta tag, then a full solution where there is a pretty button on the page and some javascript to honour the preference, keeping the preference in local storage.
Bonus points for adding an event observer to detect the change in preferences from outside the browser or in dev tools.
More bonus points for having no FOUC.
Extra, extra bonus points, is to implement not just a 'dark mode', but a DARK mode. In light mode everything is kittens and rainbows, whereas in dark mode the content is kind of gruesome and 'dark'. Any subject can be treated this way, a page on say, watermelons could be full of tasty recipe ideas in light mode, but, in dark mode, it could be about dropping them off tall buildings with busy streets below...
We've again came to full circle, with so many posts damning "no dark mode" sites back then. Maybe there is enough audience now for a "BrightReader" browser extension?
I agree with this. Default, unconfigurable light mode has been around for a while, and infrastructure like the Dark Reader plugin is around to address this. There is no such thing for light mode, though.
In my opinion, light mode is better than dark mode in most situations. The only situation dark mode is better than light mode is when you're sitting in a dark room with your screen as your only light source, and most of the time that's not really a healthy situation to be in. Dark mode is a crutch. Turn on a light or go to sleep.
Light mode might be annoying to read in no-light environments, but dark mode is nigh impossible to read in high-light environments. Ever try to read a dark mode UI on your phone on a bright summer's day? Can't read a thing, even with brightness cranked all the way up.
> The only situation dark mode is better than light mode is when you're sitting in a dark room with your screen as your only light source, and most of the time that's not really a healthy situation to be in. Dark mode is a crutch. Turn on a light or go to sleep.
It's always been strange to me how many people without a medical reason for doing so want to sit in dark rooms like cave trolls, but there we are.
At least now operating systems all have switchable modes that get reported to the browser. The browser can/should adapt to whatever setting the OS reports.
But UI design is, with a few islands of rationality in history from people like Paul Fitts, mostly a cascade of poorly applied vibes and fads. First people say that contrast is bad, so then people don't use enough contrast. Then people say that brightness is bad, so people don't use enough brightness. Then people realize why contrast and brightness were important all along and the circle of life continues.
> It's always been strange to me how many people without a medical reason for doing so want to sit in dark rooms like cave trolls, but there we are.
As a millennial, I grew up with rooms being lit by 1-3 relatively dim lampshaded 40-60w incandescent bulbs at night. As a result that’s what feels comfortable and relaxing to me as an adult. Rooms at home being brightly lit at night feels grating and reminiscent of a grocery store or hospital or something.
> Rooms at home being brightly lit at night feels grating and reminiscent of a grocery store or hospital or something.
Look into getting warm white lights. For some reason cool white lights are super common while I do think most people at home would actually prefer warm white.
Oh yeah, I’m a big fan of warm lights and have been using them for a while. Still don’t like them bright at night. Lights that are indirect (e.g. under counter) I can deal with being considerably brighter but for your typical table/floor lamp, 60W incandescent equivalent is the upper limit. I don’t like ceiling pot lights at all unless the bulb can be dimmed.
As a sibling comment expresses, it’s their unshaded nature. The light is too direct/harsh and can introduce glare. They can also wind up in peripheral vision easily, particularly when sitting down and looking up at someone standing or at an object high on the wall.
Indirect/shaded lamps that diffuse the light over a larger area and reduce its intensity are preferable.
> It's always been strange to me how many people without a medical reason for doing so want to sit in dark rooms like cave trolls, but there we are.
Because screens are not bright enough to use outside or in well-lit environments.
If E-ink or similar technology manages to get a bit better refresh rates, it's going to change building architecture in the entire industrialized world.
I'll grant you outside, because the power of the sun is immense, but they're definitely bright enough to use in any well-lit indoor environment. Do you mean if the lights are behind your head instead of overhead? That's either bad lighting or bad ergonomics, and I'm sorry if you must suffer through that. That sucks.
An ergonomic screen arrangement, with the display placed such that you're not looking downward at it, should make it basically impossible for an overhead indoor light to interfere with your view.
> If E-ink or similar technology manages to get a bit better refresh rates, it's going to change building architecture in the entire industrialized world.
Fingers crossed. I remember yearning for the breakout of transflective displays that never happened.
I don't think I phrased that right. What I mean is environments with a lot of natural light, for example from big windows. Or a café without walls to the outside, letting the sunlight in, but not right overhead. I guess this kind of architecture is not so common in colder countries, now that I think of it.
The sun is tyrannical where I live, so with current display technology, offices are indeed built somewhat like caves.
I feel kind of traumatized for years of forced light mode everywhere. It hurts my eyes.
In bright sun when outside, I use light mode. Allmost everywhere else, I won't. So please @everyone thinking like this, don't assume, what is best for me, because your taste is different.
Yeah, most people use their screens with brightness cranked up and then wonder why they have all sort of problems.
The trick is to set a low brightness, in my case it's a little below what you would call comfortable, but that's because you adapt to it in a sec and will be perceived as good.
If you can't set it too low on the monitor, set brightness to 0 and lower the contrast. If it's still too bright use also brightness/contrast controls in your GPU settings. It is also needed to adjust the settings during the day. But having a more controlled light in your room is a better option.
Once you start getting comments from others that they can't see shit on your screen then you've set the correct level :)
Another very often forgotten thing is to set up correct gamma correction! Yes that thing from CRTs is often needed on LCDs too! LCDs can produce quite big contrast which is unpleasant, for example I set mine to 1.3, fixed it nicely for me.
One approach to find a good value is to have antialiased text both in white-on-black and black-on-white and switching between these. Once the apparent thickness is the same then you've got the right value. Beware of ClearType settings though, you may need to do the test with a classic antialiasing instead.
The result is that you can comfortably use light mode in total dark room without any issues.
Yeah monitor controls can be a problem. You can download an utility to set it from the computer, it's much more comfortable. I'm using one from my monitor vendor, but there are also generic ones.
Search for utilities that can set the monitor using DDC (Display Data Channel).
A difficulty is that the appropriate screen brightness varies with the content it's displaying. Going from a low-contrast dark site to a white background is especially jarring.
Or from text and diagrams (which often contain large single-color areas) to photos and videos. The default HN color scheme looks much brighter than the bright daylight photo I currently have as a desktop background.
With a properly set monitor and gamma setting there is no issue with switching between light and dark mode at all (even in a pitch black room at night). I use it regularly, I prefer light mode but I also use dark mode for stuff like terminals. So I switch a lot between these.
Your proposal is to decrease the dynamic range of the display. This will certainly achieve the goal of making switching between light and dark backgrounds more comfortable, but makes it worse for viewing photographs or videos. It's also not ideal when doing any amount of design, as most viewers won't have their screens set up the same way.
Photographs and videos seems allright to me, maybe I'm just used to it. I like that the dark regions are visible (esp. when IPS LCDs have not that great blacks due to the backlight).
I always hated it on CRTs where photographs were too dark, had to use a really big gamma correction on them (2.5), I guess I've got used to it from these times because it was a necessity to be compatible with LCDs.
The photos and videos are more dull when compared to a reality, but consistent with other stuff on the screen. I have no problem doing color stuff for things like textures, website design etc. The relative comparison to other material is enough for me. I've been working with graphics designers with calibrated monitors and didn't get any complaints.
But I don't do anything that requires working with calibrated monitors, like printing. Though it's hard to tell if it would be an issue. You need to do test prints anyway. You have to use specific named colors (Pantone). Based on that you can just imagine how it would look, no need to have it precisely shown all the time.
Nah some of us need dark mode 24x7 and actually benefit from it even in broad daylight. Not fair to make this assertion and assume everyone is like you.
On my system, the dark reader plugin also has an option to force a light theme.
Actually, the browser has the ability to set a default background and foreground anyway, so this extension would be unnecessary if websites would behave properly and respect these defaults unless they really need to. We live in an unfortunate world where a “actually respect my preferences” extension is necessary, but since it is necessary, it should be noted that it covers both options. Overall the situation is pretty stupid but hey at least we’ve got workarounds, right?
Browsers shouldn't set a preferred colour scheme by default.
I think the prefers-color-scheme media query would be respected on more sites if by default it had the value "unset" or something, instead of defaulting to "light" or "dark".
I personally don't respect it on my sites for this reason. 99% of people visiting my sites won't actually have set this value themselves.
All the dark mode extensions I've used also would work for making pages light mode.
For me, I have trouble focusing when reading light mode content, but dark mode is perfectly fine (light backgrounds seem not still, as if there is movement, and this effect lessens the darker the background is.
> Light mode might be annoying to read in no-light environments, but dark mode is nigh impossible to read in high-light environments.
Backlit screens are difficult to read in high-light environments regardless of whether you're reading black text on white or white text on black. I use white-on-black ("dark mode") on my e-ink Kindle to read outside all the time. And the same is true on our Daylight computer. White-on-black remains my preference in high-light environments.
Are you confusing the brightness setting on the display with "dark" and "light" mode? Because I always have the brightness on my monitors at max when the lights are on. I practically never change it.
As a software developer, who codes about 15 hours a day (day job and personal projects), I ditched "light mode" many years ago as it's too harsh on my eyes to be staring at a bright white screen that many hours a day. Dark mode is far easier to look at for long periods of time.
I have no trouble reading code in dark mode in a well lit room. If it were difficult to read, it wouldn't last 15 minutes for my needs. I don't code in "D4rK M0D3" in the dark, I'm not a l337 H4CK3r.
>Ever try to read a dark mode UI on your phone on a bright summer's day?
Phone in direct sunlight is one thing. That isn't the way most people use devices, that's a more rare use case than sitting at a desk 8 hours a day staring at a bright screen. There are also high-contrast modes for eyesight challenged people, which can be used effectively in bright sunlight too, but I'm not going to code that way for hours a day if I don't really need to. Phones and other devices also have adaptive brightness, so if you are in a dark room the phone's display brightness is going to be dimmer automatically, and I'm not really sure you know the difference between "dark mode" and "brightness turned down". So using a phone screen and high contrast required for using screens in direct bright sunlight is a poor example to support your argument. Maybe you also need to qualify all of your arguments with "on a mobile device in bright sunlight", because that isn't the main use case for "dark mode".
> I ditched "light mode" many years ago as it's too harsh on my eyes to be staring at a bright white screen that many hours a day. [...] I always have the brightness on my monitors at max when the lights are on.
If your screen at the brightest setting hurts your eyes, why would you use it like that?
I enjoy the full brightness of the display when it calls for it, when watching videos or video games, when the screen isn't 99% full-on white pixels. I also enjoy the crispness and contrast of white text on a dark background when the display brightness is at maximum. No, I do not enjoy using a display at low brightness, and I really don't like being blasted by full-on white background with dark text on it all day every day.
I like Pure Black mode because the black pixels actually turn off on my screens, making it much more pleasant to look at. Even in broad daylight! I wish Pure Black mode was an option separate from Dark and Light mode, like it is on some Android apps. For now I get by by minimizing brightness in Dark Reader, but it is a bit clunky.
Sleep hygiene. I'm in college and I know too many people that waste away online until 3am and are always tired and then down coffee after coffee during the day.
> sitting in a dark room with your screen as your only light source
is also really not great for your eyes, in the same way that having a bright light source in your field of vision (e.g. a window without blackout shades directly behind your monitor) isn't either.
I'm using computers/TV/Phones in dark room, on an average 12h+ a day, for ~20 years. My eyes are just fine. Last time (and only time) I went to an eye doctor two years ago because people like you keep saying my eyes are damaged, the doctor asked me why am I wasting my money going to eye doctor.
Just because someone stays up till 3AM (which I have done for years), doesn't mean they need to sleep less or feel always tired. This has nothing to do with using computer in dark room which is possible even at 3PM.
Also, I don't drink coffee (less than 5 times a year). There are plenty of people who sleep at proper time and still drink a lot of coffee all day.
I use dark mode during the day in rooms with lots of natural light spilling in because that’s what’s felt better to me ever since we collectively decided that light themes need to use stark white and very light grays instead of the mid-grays dappled with mid-colors that used to be popular. Dark mode is a bandaid for the needlessly bright themes that became the norm with the advent of flat design.
As someone that had cataracts, light mode was very hard to read. It was like looking directly into high beams. I used a dark reader plugins that was alright, but was not the same as a site designed to support dark mode.
In my experience, high contrast dark mode is readable in high-light environments, but it causes the issue the images in the article show.
Beyond that, I have no preferences between light and dark modes on laptop screens and smaller. But I prefer having at least some dark elements visible on large screens, because floaters can be distracting against large bright surfaces. Usually it's a terminal window with the traditional light gray on black color scheme, but I tend to use dark mode in IDEs and other full-screen apps.
I use dark mode in a (moderately) lit room, because it makes me focus better. Even colorschemes can affect my state of mind and make it work differently. I’m not even talking about effectiveness here, just comfort, although they correlate. I can’t just choose light mode.
When screen is too dark (sunlight, etc), I make it brighter. Requires >=400 nit or whatever that unit is for an average day.
> The only situation dark mode is better than light mode is when you're sitting in a dark room with your screen as your only light source
It's really not that extreme. Dark mode is more comfortable as soon as it's dark outside (this time of year that starts between 3 and 4 pm) unless I'm flooding my entire room with enough light to replace the sunlight. I still have the lights on, but none of that light is as bright/white as an average white webpage. Even with screen brightness turned down and a blue light filter, an all-white webpage is usually just too much white.
> Light mode might be annoying to read in no-light environments, but dark mode is nigh impossible to read in high-light environments.
This is just completely opposite for me. Reading in dark mode is only uncomfortable if there's sunlight basically directly behind the screen, while light mode is only really comfortable in high-light environments.
Light/Dark modes at their extremes are both annoying. White on black or black on white are both to extreme. The best solution IMO are mid-level colors. I personally prefer the schemes with darker grey backgrounds and lighter grey (or other lighter color) foreground, but the opposite isn't bad either. What are bad is that the default light modes are generally much to light. A random site I have open right now has a background color of #f2f2f2 w/ text color of #151515, it is only tolerable to read if I have my monitor red-shifted to around 4200 degrees (in a well lit room w/ lots of natural light).
> Light mode might be annoying to read in no-light environments, but dark mode is nigh impossible to read in high-light environments. Ever try to read a dark mode UI on your phone on a bright summer's day? Can't read a thing, even with brightness cranked all the way up.
This. once stuck outside with limited battery and tried switching to light mode. could instantly reduce brightness and still see everything.
the nature of lcd display makes it hard to display contrast without backlighting. but the early ones could be effective by showing dark details on a blank slate. this situation brought back my appreciation for having this mode.
Also; because system mode happens to be dark, doesn't mean that the users would like dark mode by default. Every dark mode is not equal, and I'd like to start with light mode if possible.
Thanks for posting this, it's an interesting perspective that I hadn't considered before. Ideally, sites would respect user preferences such as prefers-color-scheme and prefers-reduced-motion. And, in fact, I just checked MDN and see there is prefers-contrast:
Your light mode privilege is showing but seriously, maybe instead of writing an article with a tone about everything that's wrong with a preference you have you could instead. do what every dark mode user has done and like you said.. just override the css. And then write an article with a tone about how you accomplished it. This just feels like complaining for the sake of complaining.
Seems like a fashion thing, but the Linux distribs I've recently checked out all defaulted to a dark mode. Fine for night but a pain to read normally :(
I don't know, but I have the exact same issue. White text on a black background actually hurts my eyes after a paragraph of reading, and then when I look away I see those grey bands across my vision for the next 20 seconds. As soon as I land on such a page, I either immediately back out or, if it's a subject I really want to read, I go to Safari and turn on reader mode.
I have the exact same issue too and wish I had a name for it. I had been assuming it was related to astigmatism since I also have issues with low-light environments especially with reflections (e.g. hate watching TV in a dark room, don't like driving at night especially in rain) but it seems like others who have this issue aren't mentioning it so now I'm doubting that.
A little bummed seeing how hostile most of the comments here are but I guess it's to be expected if most commenters are seeing very differently than how I and the author are.
I suffer from the same issue and I've always assumed it was astigmatism as well. There are different types of astigmatism so perhaps some types have this issue and some don't? I'm unsure, but I know that dark mode is legitimately hard for me to read.
exactly. perhaps a case of their eyes and screen refresh rate being incompatible. something smells undiagnosed. whatever it may be, definitely a PEBCAK issue
Well hang on a sec. If a website is dark with light text and has just that one style, then that's it's theme, it's vibe. Dark mode only exists if there is a light mode, and give versa.
Don't force having to maintain two modes on websites who don't want to?
I think the poster was talking about phrasing, “dark mode” implies there are modes to switch. The article seems to incorrectly be conflating dark mode vs dark themes. Dark themes tend to be unadjustable.
IMHO I usually just flip to the reader mode on my phone browser or desktop browser when I don’t like the theme of a website. This obviously doesn’t work for all websites but it’s a nice work around since most reader modes allow you to adjust coloring yourself.
They actually are saying that nobody should have dark mode sites, except watered down ones.
What are these "dark-mode" (misnomer) sites that don't have a comfortable contrast ratio? I know there are some, but I think they're including a broad swath of primarily light-on-dark sites in this group.
Adjust the brightness on your screen.
X's is pretty good, the background is #000000 and there is some #ffffff content, the text is a bit farther from #ffffff than I'd like but pretty close. https://colorpalettecombos.netlify.app/
Curiously, the contrast ratio wasn't a good signal for me. The white on black text didn't strain my eyes but this did:
> However, light gray text on a dark gray background is easy on my eyes. Here the background is #666 and the text is #E0E0E0 which creates a contrast ratio of 4.34:1.
Github used to do this. The result is their dark mode isn't useful for anyone. However, They revamped their color scheme later and made it comfortable to read.
Graybeard opinion: most sites shouldn't deal at all with colors.
Just write plain html [0] and let your users choose.
Default browser styles are not only stylish, they are also accessible and responsive by default.
Not just light vs. dark. I wish web sites would respect my system's preferences in general. If my OS theme is purple Comic Sans text on top of a yellow brick wall background, then my browser should respect that. I want to read text using the full width of the browser rather than a tiny 5 inch column down the middle of it, I shouldn't have to perform wizardry in the browser settings, conjure up some overriding CSS, or install extensions to do this. The browser should just say "tough shit, web developer, the user's preference wins."
Browsers have handed over way too much control to developers to ignore what the user wants. So much for being a "user agent." Browsers are more like the developer's agent.
Yes, and too many applications go out of their way to ignore user preferences on desktop, too! It's a major problem IMO. The user should be in charge of their computer.
Well, there's not much you can do about yellow background, but forcing Comic Sans is as easy as setting it as your preferred font and then deselecting "Allow pages to choose their own fonts", at least in the Firefox settings page.
This is what I do and it makes browsing the web so much better.
Please don't force low contrast ratios on users. Not everyone is calibrated to >100 nits and viewing your content in a bright but sensible ambient environment
The recommended grey-on-grey may be unreadably low in contrast when viewed on, for example, 0 brightness in a pitch black room, or in direct sunlight
The full SDR colour range is there to be used, this isn't HDR where you need to limit things to not blind your users
I don't agree. I have the same problem described on the article; I can't read websites with white text over a pitch black background. My eyes hurt after a while. At the same time, I use a dark theme on my IDE, but it feels like it's better on my eyes for some reason.
That’s because the dark theme of your IDE also uses lower contrast. Which makes it hard to read for other parts of the population, even if they otherwise like dark mode. Contrast should be a user setting.
I’m dating myself, but this was all so easy with CRT monitors, which had a simple analog contrast dial, and everyone just set it to their preferred level.
Simplest thing is to have light and dark mode themes, use whatever the user has set for their system settings, and also have a toggle to switch between light and dark. You may like dark mode for most things you browse but then would prefer something in light mode.
The problem with this is that you now have 2x the UX testing to make sure everything is useable and looks aesthetically pleasing. Probably OK for a large website, but as a solo entrepreneur, that ends up adding a lot of overhead.
YES! I cannot understand the grey on grey on grey anti-readability obsession. I cannot stand it. It's ugly and hard to read. I wish we'd all just stop doing it.
267 comments
[ 3.2 ms ] story [ 265 ms ] threadThe author also changes their mind halfway through and decides the problem is actually color contrast, not dark mode.
Ironically they end by saying they'll use an invert filter as a workaround, while for those who prefer dark mode if doing the same on the author's own stark white bg/black text site (such as Vivaldi's 'Invert Mode') will produce the very contrast ratio in dark they're complaining about :p
If you wanna argue that we shouldn't force dark mode, maybe don't go around forcing light mode. My eyes hurt.
Neither dark mode nor light mode is the one true “main” option. We had dark mode for a long time with terminals. Then light mode a long time with word processors and the web and OSes. And now we kinda have both.
[1]: https://anthonyhobday.com/sideprojects/containercolours/
/* Dark mode */ @media (prefers-color-scheme: dark) { ... }
The issue with both dark and light modes is so many designers seem to have jumped onto the idea that colour schemes have to be either bright white or darkest black.
I'd much rather see colours that are 'slightly darker' at night and 'slightly lighter' in the daytime. For one thing there are still so many websites with no colour schemes setup at all so if you avoid going to extremes it minimises the contrast difference.
The optimal approach is applying the appropriate `prefers-color-scheme` using CSS alone, while additionally allowing a theme override using JS/storage. Fewer do this though, even though it wouldn't require any cookies and thus no consent dialog.
The worst are sites that only have theme switching gated behind registration.
On page load you get your javascript to check the mode and check the override to add a class to the whole page. It is this class that implements the desired light or dark theme.
Fighting against you is what the browser is doing. You can put a meta tag in to force it to respect one theme or the other so it does not go freestyling.
People that have a page permanently set to light mode (or dark mode) have put in the meta tag but they haven't done the extra work to implement some meaningful choice.
In summary, there is auto, where the browser does its best, one mode enforced with a meta tag, then a full solution where there is a pretty button on the page and some javascript to honour the preference, keeping the preference in local storage.
Bonus points for adding an event observer to detect the change in preferences from outside the browser or in dev tools.
More bonus points for having no FOUC.
Extra, extra bonus points, is to implement not just a 'dark mode', but a DARK mode. In light mode everything is kittens and rainbows, whereas in dark mode the content is kind of gruesome and 'dark'. Any subject can be treated this way, a page on say, watermelons could be full of tasty recipe ideas in light mode, but, in dark mode, it could be about dropping them off tall buildings with busy streets below...
In my opinion, light mode is better than dark mode in most situations. The only situation dark mode is better than light mode is when you're sitting in a dark room with your screen as your only light source, and most of the time that's not really a healthy situation to be in. Dark mode is a crutch. Turn on a light or go to sleep.
Light mode might be annoying to read in no-light environments, but dark mode is nigh impossible to read in high-light environments. Ever try to read a dark mode UI on your phone on a bright summer's day? Can't read a thing, even with brightness cranked all the way up.
It's always been strange to me how many people without a medical reason for doing so want to sit in dark rooms like cave trolls, but there we are.
At least now operating systems all have switchable modes that get reported to the browser. The browser can/should adapt to whatever setting the OS reports.
But UI design is, with a few islands of rationality in history from people like Paul Fitts, mostly a cascade of poorly applied vibes and fads. First people say that contrast is bad, so then people don't use enough contrast. Then people say that brightness is bad, so people don't use enough brightness. Then people realize why contrast and brightness were important all along and the circle of life continues.
As a millennial, I grew up with rooms being lit by 1-3 relatively dim lampshaded 40-60w incandescent bulbs at night. As a result that’s what feels comfortable and relaxing to me as an adult. Rooms at home being brightly lit at night feels grating and reminiscent of a grocery store or hospital or something.
Look into getting warm white lights. For some reason cool white lights are super common while I do think most people at home would actually prefer warm white.
Things can be bright and cozy.
Why not? Is it not better for lights to be overhead and not directly in your field of view?
Indirect/shaded lamps that diffuse the light over a larger area and reduce its intensity are preferable.
Because screens are not bright enough to use outside or in well-lit environments.
If E-ink or similar technology manages to get a bit better refresh rates, it's going to change building architecture in the entire industrialized world.
An ergonomic screen arrangement, with the display placed such that you're not looking downward at it, should make it basically impossible for an overhead indoor light to interfere with your view.
> If E-ink or similar technology manages to get a bit better refresh rates, it's going to change building architecture in the entire industrialized world.
Fingers crossed. I remember yearning for the breakout of transflective displays that never happened.
The sun is tyrannical where I live, so with current display technology, offices are indeed built somewhat like caves.
Also maybe if you set your screen brightness inappropriately high.
I feel kind of traumatized for years of forced light mode everywhere. It hurts my eyes.
In bright sun when outside, I use light mode. Allmost everywhere else, I won't. So please @everyone thinking like this, don't assume, what is best for me, because your taste is different.
The trick is to set a low brightness, in my case it's a little below what you would call comfortable, but that's because you adapt to it in a sec and will be perceived as good.
If you can't set it too low on the monitor, set brightness to 0 and lower the contrast. If it's still too bright use also brightness/contrast controls in your GPU settings. It is also needed to adjust the settings during the day. But having a more controlled light in your room is a better option.
Once you start getting comments from others that they can't see shit on your screen then you've set the correct level :)
Another very often forgotten thing is to set up correct gamma correction! Yes that thing from CRTs is often needed on LCDs too! LCDs can produce quite big contrast which is unpleasant, for example I set mine to 1.3, fixed it nicely for me.
One approach to find a good value is to have antialiased text both in white-on-black and black-on-white and switching between these. Once the apparent thickness is the same then you've got the right value. Beware of ClearType settings though, you may need to do the test with a classic antialiasing instead.
The result is that you can comfortably use light mode in total dark room without any issues.
Search for utilities that can set the monitor using DDC (Display Data Channel).
I have written another post about how to set the monitor: https://news.ycombinator.com/item?id=42762770
I always hated it on CRTs where photographs were too dark, had to use a really big gamma correction on them (2.5), I guess I've got used to it from these times because it was a necessity to be compatible with LCDs.
The photos and videos are more dull when compared to a reality, but consistent with other stuff on the screen. I have no problem doing color stuff for things like textures, website design etc. The relative comparison to other material is enough for me. I've been working with graphics designers with calibrated monitors and didn't get any complaints.
But I don't do anything that requires working with calibrated monitors, like printing. Though it's hard to tell if it would be an issue. You need to do test prints anyway. You have to use specific named colors (Pantone). Based on that you can just imagine how it would look, no need to have it precisely shown all the time.
Actually, the browser has the ability to set a default background and foreground anyway, so this extension would be unnecessary if websites would behave properly and respect these defaults unless they really need to. We live in an unfortunate world where a “actually respect my preferences” extension is necessary, but since it is necessary, it should be noted that it covers both options. Overall the situation is pretty stupid but hey at least we’ve got workarounds, right?
I think the prefers-color-scheme media query would be respected on more sites if by default it had the value "unset" or something, instead of defaulting to "light" or "dark".
I personally don't respect it on my sites for this reason. 99% of people visiting my sites won't actually have set this value themselves.
I mean, they really don't (the defaults are exactly what they have been since Mosaic left the scene). Unless the user tells them to do something else.
And at that point, it's my computer, and I told it to do something, why shouldn't it do that?
It's inherited from their operating system settings. Dark theme is typically opt-in.
For me, I have trouble focusing when reading light mode content, but dark mode is perfectly fine (light backgrounds seem not still, as if there is movement, and this effect lessens the darker the background is.
Backlit screens are difficult to read in high-light environments regardless of whether you're reading black text on white or white text on black. I use white-on-black ("dark mode") on my e-ink Kindle to read outside all the time. And the same is true on our Daylight computer. White-on-black remains my preference in high-light environments.
As a software developer, who codes about 15 hours a day (day job and personal projects), I ditched "light mode" many years ago as it's too harsh on my eyes to be staring at a bright white screen that many hours a day. Dark mode is far easier to look at for long periods of time.
I have no trouble reading code in dark mode in a well lit room. If it were difficult to read, it wouldn't last 15 minutes for my needs. I don't code in "D4rK M0D3" in the dark, I'm not a l337 H4CK3r.
>Ever try to read a dark mode UI on your phone on a bright summer's day?
Phone in direct sunlight is one thing. That isn't the way most people use devices, that's a more rare use case than sitting at a desk 8 hours a day staring at a bright screen. There are also high-contrast modes for eyesight challenged people, which can be used effectively in bright sunlight too, but I'm not going to code that way for hours a day if I don't really need to. Phones and other devices also have adaptive brightness, so if you are in a dark room the phone's display brightness is going to be dimmer automatically, and I'm not really sure you know the difference between "dark mode" and "brightness turned down". So using a phone screen and high contrast required for using screens in direct bright sunlight is a poor example to support your argument. Maybe you also need to qualify all of your arguments with "on a mobile device in bright sunlight", because that isn't the main use case for "dark mode".
If your screen at the brightest setting hurts your eyes, why would you use it like that?
Please explain.
> sitting in a dark room with your screen as your only light source
is also really not great for your eyes, in the same way that having a bright light source in your field of vision (e.g. a window without blackout shades directly behind your monitor) isn't either.
I'm using computers/TV/Phones in dark room, on an average 12h+ a day, for ~20 years. My eyes are just fine. Last time (and only time) I went to an eye doctor two years ago because people like you keep saying my eyes are damaged, the doctor asked me why am I wasting my money going to eye doctor.
Also, I don't drink coffee (less than 5 times a year). There are plenty of people who sleep at proper time and still drink a lot of coffee all day.
Beyond that, I have no preferences between light and dark modes on laptop screens and smaller. But I prefer having at least some dark elements visible on large screens, because floaters can be distracting against large bright surfaces. Usually it's a terminal window with the traditional light gray on black color scheme, but I tend to use dark mode in IDEs and other full-screen apps.
When screen is too dark (sunlight, etc), I make it brighter. Requires >=400 nit or whatever that unit is for an average day.
It's really not that extreme. Dark mode is more comfortable as soon as it's dark outside (this time of year that starts between 3 and 4 pm) unless I'm flooding my entire room with enough light to replace the sunlight. I still have the lights on, but none of that light is as bright/white as an average white webpage. Even with screen brightness turned down and a blue light filter, an all-white webpage is usually just too much white.
> Light mode might be annoying to read in no-light environments, but dark mode is nigh impossible to read in high-light environments.
This is just completely opposite for me. Reading in dark mode is only uncomfortable if there's sunlight basically directly behind the screen, while light mode is only really comfortable in high-light environments.
This. once stuck outside with limited battery and tried switching to light mode. could instantly reduce brightness and still see everything.
the nature of lcd display makes it hard to display contrast without backlighting. but the early ones could be effective by showing dark details on a blank slate. this situation brought back my appreciation for having this mode.
https://developer.mozilla.org/en-US/docs/Web/CSS/@media/pref...
A little bummed seeing how hostile most of the comments here are but I guess it's to be expected if most commenters are seeing very differently than how I and the author are.
Don't force having to maintain two modes on websites who don't want to?
> If dark mode is a characteristic of your brand, please ensure you choose a comfortable contrast ratio for the text.
IMHO I usually just flip to the reader mode on my phone browser or desktop browser when I don’t like the theme of a website. This obviously doesn’t work for all websites but it’s a nice work around since most reader modes allow you to adjust coloring yourself.
What are these "dark-mode" (misnomer) sites that don't have a comfortable contrast ratio? I know there are some, but I think they're including a broad swath of primarily light-on-dark sites in this group.
Adjust the brightness on your screen.
X's is pretty good, the background is #000000 and there is some #ffffff content, the text is a bit farther from #ffffff than I'd like but pretty close. https://colorpalettecombos.netlify.app/
> However, light gray text on a dark gray background is easy on my eyes. Here the background is #666 and the text is #E0E0E0 which creates a contrast ratio of 4.34:1.
Too many leave theirs at eye-searingly bright and then complain.
[0] https://motherfuckingwebsite.com/
Browsers have handed over way too much control to developers to ignore what the user wants. So much for being a "user agent." Browsers are more like the developer's agent.
The developer needs to do additional work to un-standardize their application.
This is what I do and it makes browsing the web so much better.
The recommended grey-on-grey may be unreadably low in contrast when viewed on, for example, 0 brightness in a pitch black room, or in direct sunlight
The full SDR colour range is there to be used, this isn't HDR where you need to limit things to not blind your users
I'm sure there are filters to do that on both desktop and mobile.
I’m dating myself, but this was all so easy with CRT monitors, which had a simple analog contrast dial, and everyone just set it to their preferred level.
What kind of eye condition or monitor does he have?