I’ve built a simple toggle for the header that switches between two themes on click.

ezgif-1-3a57fa471d85: 548x120,75%

:hammer_and_wrench: Github repo: https://github.com/awesomerobot/discourse-header-theme-toggle

:man_shrugging: https://meta.discourse.org/t/how-do-i-install-a-theme-or-theme-component/63682/44

In the theme component’s settings, you can define the two themes:

:warning: Please note

  • Both themes must have Theme can be selected by users enabled, and both themes must also have this theme component added.

  • The theme name is used in the toggle. I strongly recommend short names!

  • I have not yet added mobile support, so this only works on desktop for now

:beers: Inspired by @B-iggy’s Alien Night Theme & https://meta.discourse.org/t/theme-switcher-component/113460, and heavily borrowing from @sam’s https://meta.discourse.org/t/hamburger-theme-selector/61210