This Week's Sponsor:

Winterfest 2024

The Festival of Artisanal Software


Safari Technology Preview Allows Websites to Switch Themes Based on Mojave’s Dark Mode

With Mojave, Apple introduced a user-selectable Dark Mode. Although Dark Mode is implemented throughout Mojave and Apple’s system apps, it’s not automatic. Third-party developers have to update their apps to adopt the feature. Many developers have already added Dark Mode support, but when you run across one that hasn’t, it can be jarring.

Safari has a similar problem. Although the browser incorporates Mojave’s Dark Mode, which makes the app’s chrome dark, websites have no way to detect if a Mac is running in Light or Dark Mode. As a result, even if a site has light and dark themes like MacStories does, the theme has to be switched manually.

Safari Technology Preview 68 changes this by adding support for the prefers-color-scheme media query. Websites that implement the feature will be able to detect if a user’s system is set to Light or Dark Mode and apply a light or dark theme to match the user’s preference. Similar to apps, website owners still need to implement a dark theme for their sites, but if they do, the new feature will switch themes automatically.

Safari has a relatively small piece of the overall browser market, so broad adoption of dark themes is by no means an inevitability. However, I’m glad to see the feature coming to Safari soon because if you use Dark Mode on a Mac, bright white webpages clash with the rest of the UI.

Access Extra Content and Perks

Founded in 2015, Club MacStories has delivered exclusive content every week for nearly a decade.

What started with weekly and monthly email newsletters has blossomed into a family of memberships designed every MacStories fan.

Learn more here and from our Club FAQs.

Club MacStories: Weekly and monthly newsletters via email and the web that are brimming with apps, tips, automation workflows, longform writing, early access to the MacStories Unwind podcast, periodic giveaways, and more;

Club MacStories+: Everything that Club MacStories offers, plus an active Discord community, advanced search and custom RSS features for exploring the Club’s entire back catalog, bonus columns, and dozens of app discounts;

Club Premier: All of the above and AppStories+, an extended version of our flagship podcast that’s delivered early, ad-free, and in high-bitrate audio.