Help me please

Hi, I’m french (nobody is perfect!) Sorry for my english, google is my friend!
Like everything new in your beautiful software, I wish to change the theme of home assistant.
I read the doc https://home-assistant.io/components/frontend/, but I do not understand anything!
Question:
-All the parameters must be in configuration.yaml?
-How to add the 2 services related to themes?
As you can see I’m not a champion, but I want to learn.
If you could explain me simply it will be super nice!
thank you in advance
jp

Here is a couple simple examples to follow:

Further discussions:

https://community.home-assistant.io/search?q=themes

Simple, simple … for you but not for me, sorry. I am a novice with your commands and your scripts, I am aware that it takes a minimum of knowledge, sorry but I do not understand.
How to “write” this script ?, or place it?
Thanks anyway for taking the time to answer me. I am looking for, I am looking for
jp

In your configuration.yaml, you should have a frontend key. Themes are indented beneath that like so…

frontend:
  themes:
    name_of_theme_1:
      CONFIGURATION FOR THEME 1 LISTED HERE
    name_of_theme_2:
      CONFIGURATION FOR THEME 2 LISTED HERE

Etc

Are you looking to use a specific theme always, by day/night?

Just for the day

which theme?

I do not have a preference, whatever you want, it’s just to learn …

Start off simple, then you can expand as you get the hang of it.

frontend:
  themes:
    happy:
      primary-color: pink

Then you can either set it manually (see here), or with an automation like below, which will take effect each time you start HA.

automation:
  - alias: 'Set theme at startup'
    initial_state: 'on'
    trigger:
     - platform: homeassistant
       event: start
    action:
      service: frontend.set_theme
      data:
        name: happy
1 Like

Ok good ! thank you very much !

I’ve tried the most basic theme and I still dont see it in the Configuration>General section. Any thought?

frontend:
  themes:
    happy:
      primary-color: pink

I’ve just tried setting up a theme as well in 0.76.2. I’ve edited my config and I don’t see any options under Configuration->General either.

# Enables the frontend
frontend:
  themes:
    test:
      primary-color: green

Is this a bug?

If it’s a bug, it seems to be infectious. I have the same issue. I thought I was nuts for a while there.
BTW, it was working under 0.75.x

Well, that is three of us that have seen this. I’ve filed a bug.

https://github.com/home-assistant/home-assistant/issues/16197

So, it isn’t a bug. It is a combination of out-of-date documentation and a not-fully-released feature.

User Authentication is scheduled to be released in version 0.77. This introduces user profiles, which is where the theme selector has already been moved to in 0.76. So you can’t edit your theme until you manually enable User Authentication. Add the config below to configuration.yaml, reload HA, and then create a user. Then you can update your theme.

  auth_providers:
   - type: homeassistant
   # uncomment this to enable backwards compatible API password support
   # - type: legacy_api_password

See this post.

1 Like

Kool! Just reconfigured and yes… it works. Thank you very much for the escalation and getting back to us.
Now… the only problem is when I log off and go back in, the theme setting is not retained. :slight_smile:

1 Like

@dickcollier @bakerbug The theme settings are now under Profile. Just click your Icon at the top and you’ll see it under there.

I had the same problem :unamused: