core: frontend.set_theme doesn't change default theme modes

The problem

service: frontend.set_theme
data:
  name: default
  mode: dark

should change current (=default) theme mode to dark, but it doesn’t work - nothing happens (it doesn’t work neither with mode: light)

What version of Home Assistant Core has the issue?

core-2023.12.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

No response

Link to integration documentation on our website

https://www.home-assistant.io/integrations/frontend/#defining-themes

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

https://community.home-assistant.io/t/change-dark-light-mode-of-default-theme-based-on-automation/516181/2 https://community.home-assistant.io/t/day-night-theme-switching-automation/24887/17 https://community.home-assistant.io/t/set-default-light-dark-lovelace-theme/412486

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 3
  • Comments: 20 (5 by maintainers)

Most upvoted comments

Every response from the developers on this topic was something like, “It’s not supposed to work this way.” and then goes on to describe a use case (for the current bugged behavior) that makes no sense while trying to convince everyone that no one really wants to be able to switch the default mode from auto to light or dark. 😄

@cociweb It is not. I can confirm that. I wanted to double check it also on my side, but I first needed to unblock myself using the “Use default theme”. The only way how I got my scenario working, was to create two separate themes.