Organize
By default, Home Assistant will show all of your devices and services in the default view. You can change this from within the groups.yaml file on the server.
Open your groups file in Visual Studio Code and you’ll find a blank slate to work with. Let’s start by grouping up some items. Here is a group of the items in my bedroom.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bedroom: | |
name: Bedroom | |
entities: | |
– switch.bedroom_lamp | |
– switch.bedroom_fan | |
– switch.bedroom_speaker |
Put together your first group, save, check the configuration, and restart Home Assistant.
Ta-Da! You’ve got a group. Make a few more and we can organize them even further.
- The groups.yaml file can be used to change the default view and create tabs that can be populated by other groups.
- Change the default view by adding default_view: to the file.
- Then add whatever groups you want to add to it.
- Notice I used a hashtag to comment out the Christmas Tree. I’ll add it back in when the tree goes up.
- After saving and checking your configuration, your States tab should only show the entities or groups that you included within the default_view:
- If you’re comfortable enough with whats going on, you can also remove the “Welcome Home!” card by removing introduction: from configuration.yaml
- Groups can also be put within tabs at the top of the page by using view: yes in the groups file.
- I’ll move my fish tank to a new tab.
- I suggest while working within your groups file to also make groups that you want to have voice control over. As an example, I have a “bedroom” group with my lamp, fan, and speaker. I also have an “alexa_bedroom” group that has my lamp and fan because I don’t want my speaker turning on and off whenever I tell Alexa to turn my bedroom on and off.
- Save, check your configuration, and restart Home Assistant.
- You should see your new changes go into effect.
Customize
*Customizing entities has been made easier in Home Assistant 0.53. Scroll down to learn about the Customize Editor. This technique will still work, but you may prefer the editor.
Now that everything is organized, you can customize your entities.
- Navigate to your customize.yaml file and you’ll be presented with another blank canvas.
- Within the customize.yam” file, you can change names, icons, and hide groups or entities from Alexa on the Echo Dot (which will be our next step).
- Icons are added by using MDI icons.
- You will be connecting the Echo Dot to the system using the emulated_hue: component. To hide entities from this component you can use emulated_hue: false to change the name of the entity for the Echo Dot use emulated_hue_name: Using hidden: true will hide an entity inside Home Assistant. This can make an entity visible to Alexa, but not Home Assistant.
- Save and check your configuration.
- Restart and your customizations should now be visible.
Customize Editor
Home Assistant 0.53 introduced the Customize Editor. This gives you the ability to customize the same elements we just went over, but from the front end.
- In order to use the editor, you will need to have customize: !include customize.yaml in your configuration.yaml file and a customize.yaml file in your config volume on the network.
- I want to change the icon for my Fish Tank Light.
- I’ll go down and pick an attribute to override and choose icon.
- Icons are added by using MDI icons.
- Icons change immediately.
- Some customizations may require restarting Home Assistant.
Look at all of your entities
- Now that we’ve changed the default view, many of the entities have become hidden.
- You can see them in the States section of the Developer Tools.
- Now that everything is looking nice, you can add voice control!
If these guides have been helpful to you , please share them! If you have any questions, please reach out to me in the comments. Thanks for visiting!
hey, is there way to ask alexa about the room temperature via broadlink sensor?
LikeLike
Totally! I use that as a specific example when creating a custom Alexa skill here: https://smarthomehobby.wordpress.com/2017/10/01/custom-alexa-skills-launch-requests-in-home-assistant/
LikeLike
hey, if i want to create groups like you did i always get an error: ERROR (SyncWorker_0) [homeassistant.util.yaml] while parsing a block mapping
in “/config/groups.yaml”, line 1, column 1 expected , but found ”
LikeLike
oh dear i think i missed a few spacebars…it seems to work now thank you
LikeLike
But now they completly disappeared from the “HOME” States tab. my groups.yaml file:
default_view:
view: yes
entities:
– group.led_stripes
– group.lights
– group.tools
led_stripes:
name: Led Stripes
entities:
– switch.led
– switch.led_red
– switch.led_green
– switch.led_blue
– switch.led_yellow
– switch.led_white
– switch.led_orange
– switch.led_purple
– switch.led_turquois
lights:
name: Lichter
entities:
– switch.entry
– switch.lamp
tools:
name: Geraete
entities:
– switch.cooking
– senor.broadlink_sensor_temprature
where could be the problem?
LikeLike
Hey Johnny, I don’t think I see anything wrong with the words here, I can only think it might be the formatting. Consider rebuilding your groups configuration, one group at a time and restarting after each one. This can help you narrow down where the mistake is.
LikeLike
hey alex, so my groups are listed under devoloper tools but they are hidden: true
how can i change that?
LikeLike
You can change it to hidden:false wherever your customizations are found.
https://home-assistant.io/docs/configuration/customizing-devices/
LikeLike
seems like there is something with my broadlink switches cause my sensor work
LikeLike
What stopped working?
LikeLike
hey, everything works but not the group set-up:
https://i.imgur.com/uCPGybV.png
https://i.imgur.com/UHItISX.png
https://i.imgur.com/43ZVuqd.png
did i use the wrong code for switch in groups?
LikeLike
The groups look fine. I think you need “off” commands for your switches. Even if you won’t use them. What I would try, is comment out all of your switches with “#” and re-add them one at a time. Then you’ll know which switch is causing the problem.
LikeLike
if i remove the whole group section everything is shown on the home screen…
im not sure, is it about the position of the group: !include group.yaml?
cause my broadlink and sensors are before this line and my switch is after it
LikeLike
Check your file name. In the image you sent me, it’s groups.yaml but in your question you wrote group.yaml.
So it should be
group: !include groups.yaml
LikeLike
I just checked my own configuration, and I have my group component above my switch and broadlink component. Not sure if that is keeping yours from working, but it’s worth trying.
LikeLike
how many spaces before default view and every group?
LikeLike
Here’s my configuration file. https://github.com/looknsharp/homeassistant/blob/master/configuration.yaml
LikeLike
And my groups.yaml https://github.com/looknsharp/homeassistant/blob/master/groups.yaml
LikeLike
i finally found my problem i used the wrong switch names…i had to look them up under states…. thanks
LikeLike
Awesome! So is everything working now?
LikeLike
Yep, but i got some troubles about the custom alexa skill
LikeLike
I’m glad your switches are all working now. I’m always happy to do what I can to help. If you need help, do me a favor and post the question on that Post.
LikeLike