It has been well over a year since we discovered work being done that would bring “dark mode” to Chrome OS. By now, I really thought that developers would have wrapped this one up but apparently, it’s been a greater undertaking than I presumed. Every time I get a Canary update, I look for “dark mode” in the hopes that we can finally get a rough idea of when we may see this much sought after feature. I, for one, use dark mode on any and all apps that offer it and that includes the system theme on my OnePlus 8. Sadly, dark mode is still absent from even the Canary channel which is currently on version 86 of Chrome OS.
That’s not to say that it won’t eventually happen. Just last month, Robby unearthed evidence that Google was tweaking the fingerprint setup UI and desks UI for Chrome OS to account for dark mode. More recently, Chrome Story’s Dinsan Francis found a commit that is adding a “dark mode” toggle to the Chrome OS system tray. Sounds to me like the project is finally nearing completion and developers are getting the final bits and pieces in place for a roll out to Canary. That’s all fine and well but you know me. I’m not content hearing about it from another source. I like to dig in and tinker with Chrome OS and get my hands on features before developers ever intend them to see the light of day. That led me to a reddit post from January of last year in which a user was actually able to enable the Chrome OS dark mode by adding the flags using crosh, aka the Chrome OS shell environment.
Crosh is essentially a terminal for Chromebooks. Even without entering the non-secure developer mode, you can use crosh to enter a handful of commands to do things like checking your battery health or identifying the kernel version on your device. Go ahead. Give it a try. Just type Ctrl+Alt+t on your keyboard and crosh should open in a new window. Don’t worry. So long as you don’t tinker around, you aren’t going to break anything. At the
crosh> prompt, type
battery_test 1 and hit enter. The output should show you the current charging state, battery level and battery health. There are other useful commands you can use in crosh but we’ll cover those another time. Right now, we’re going to look at how I enabled dark mode on my Chromebook.
The following steps involve placing your Chromebook in developer mode, not the developer channel. This is NEVER recommended and I suggest that you NEVER do it. For starters, entering developer mode will wipe your device. Anything that isn’t backed up will be gone forever. Secondly, developer mode is “less secure” than stock Chrome OS. The verified boot that makes Chrome OS less vulnerable than other operating systems is modified and you will have root privileges that can cause irreparable harm to your device if you don’t know what you’re doing. If you do, you’re on your own. From Google: Caution: Modifications you make to the system are not supported by Google, may cause hardware, software or security issues and may void warranty.
<!– –>There, you’ve been warned. If you are a developer or someone who frequently tinkers on your Chromebook, you probably checked out on that last part but I trust that you understand the risk involved. All I’m saying is that you shouldn’t do this. You certainly shouldn’t put your device in developer mode just to do this. On that note, here is how I enabled dark mode on my Chromebook. First, I opened a crosh window and entered
shell to get to where I can leverage root access. From there, you have to the set up developer access and make the root file system writeable. This is done with the following commands at the
shell prompt. <!– –>
sudo crossystem dev_boot_signed_only=0
sudo /usr/share/vboot/bin/make_dev_ssd.sh --remove_rootfs_verification
*The second command may throw an error. If you know your way around the terminal, you should know how to fix it. If not, you should turn back now.
<!– –>Once that’s finished, you’ll need to restart your device. Next, the flags for dark mode have to be added to the chrome_dev.config file. This can be done using Vim text editor that is built into crosh and many other UNIX-like systems. To open the config file, open another crosh window and type shell and hit enter. Run the following command to open the file with Vim. It’s going to spit out a page full of stuff. Don’t panic.
sudo vi /etc/chrome_dev.conf
<!– –>Arrow down to the bottom of the page until the cursor stops. To add the dark mode flags, paste the following two lines in the space at the bottom of the config file on separate lines.
Once you have those in place, hit the escape key to move back to switch to command mode. Type
:wq and hit enter. This will save your edits and close Vim. The you will need to restart the system using the command
sudo restart ui. (If you have any other work going on in other apps or windows, you’ll want to save it before running that last command.) Your Chromebook will do a quick restart and you should be greeted with the new dark mode. After taking a look around, it’s clear to see that dark mode still has some fine-tuning to be done. When you right-click on a web page, you get a nice dark mode popup that looks really good but right-clicking in the files app still brings up a staunch white menu. For the most part, it looks really good but occasionally, some elements don’t display properly and I found myself hunting for hamburger menus by clicking into dead space.
Again, I do not suggest you mess around with this. That’s why I’m here. We have plenty of Chromebooks around here to break. Not only that, all of this resets when you get an update to Chrome OS. I suppose we’ll just have to wait for this to hit Canary before we get any more details. Until then, I’m headed back to tinkering. Shout out to u/JediBurrel for taking the time to try this out and for sharing it with the world.