Configure Home Assistant

In computing, configure means to arrange components to make a system functional. This guide will cover setting up devices to work with your Home Assistant system. Depending on which devices you have, there may be one or multiple ways to set it up. The main setup methods are through the Integrations menu or manually through the YAML files, which are both covered below.

Integrations Menu

The Integrations menu is a really easy way to connect supported devices. This is the same menu that you saw when you first connected to Home Assistant and created your account. Unfortunately, not all components will be able to be configured this way. Fortunately, many can be integrated this way, it is very user friendly, and devices are continually added to this menu.

To access the Integrations menu, go to the Configuration tab and select Integrations.
In the Integrations menu you can see any configured integrations and detected integrations to configure. You can also add new integrations by clicking the + Add Integration button in the bottom corner of the screen.
In the Set up a new integration menu, scroll to find the device you want to set up. Home Assistant will then walk you through the process of configuring it!
  1. To access the Integrations menu, go to the Configuration tab and select Integrations.
  2. In the Integrations menu you can see any configured integrations and detected integrations to configure. You can also add new integrations by clicking the + Add Integration button in the bottom corner of the screen.
  3. In the Set up a new integration menu, scroll to find the device you want to set up. Home Assistant will then walk you through the process of configuring it!

Manual Configuration

Manual configuration has the steepest learning curve when learning Home Assistant. It can be a little intimidating at first, but it is organized and gets easier to understand as you spend more time in the environment. The most important thing to remember is that YAML is picky about formatting. Most issues with manual configuration will most likely be a formatting issue. To get started working with YAML, you will need to activate advanced mode in Home Assistant, so you can access the correct settings.

Activate Advanced Mode

Go to the Profile tab in Home Assistant and scroll down to turn on Advanced Mode.
The Check Configuration tool is found in Configuration --> Server Controls.
  1. Go to the Profile tab in Home Assistant and scroll down to turn on Advanced Mode.
    • Advanced mode will give you the ability to use the Check Configuration tool.
  2. The Check Configuration tool is found in Configuration –> Server Controls.
The Check Configuration tool will verify your configuration. Invalid configurations can keep your system from starting up after a reboot.
After the check, the tool will either tell you you're configuration is valid, or it will return an error to help you correct the error.
  1. The Check Configuration tool will verify your configuration. Invalid configurations can keep your system from starting up after a reboot.
  2. After the configuration check, the tool will either tell you your configuration is valid, or it will return an error to help you correct the error.

Access and Edit YAML Files with File Editor

From the Home Assistant Add-on Store, find and click on File Editor.
  1. From the Home Assistant Add-on Store, find and click on File Editor.
From the File Editor add-on page, click Install.
After the add-on is installed, tap Start.
When the add-on is running, you can open the Web UI with the link on the bottom right-hand corner of the screen, or the new File Editor tab in the sidebar.
  1. From the File Editor add-on page, click Install.
  2. After the add-on is installed, tap Start.
  3. When the add-on is running, you can access it by clicking the Open Web UI link on the bottom right-hand corner of the screen, or the new File Editor tab in the sidebar.
You can browse the file system using the link in the upper left-hand corner.
Open configuration.yaml from the list of files.
  1. You can browse the file system using the link in the upper left-hand corner.
  2. Open configuration.yaml from the list of files.
This is your main configuration file for devices and services. Notice these lines on the bottom of the file. Using !include and a filename will force Home Assistant to look for related files in the configuration.yaml file. These files can be found in the configuration folder and can be edited the same way configuration.yaml can.
group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
  1. This is your main configuration file for devices and services. Notice these lines on the bottom of the file. Using !include and a filename will force Home Assistant to look for related files in the configuration.yaml file. These files can be found in the configuration folder and can be edited the same way configuration.yaml can.
    • The tts (text to speech) component here is an example of how a component is set up. The exact configurations can be found for each integration.
For practice, add a demo platform to your configuration by copying and pasting this YAML into your configuration.yaml file.
Save the changes. By clicking or tapping the save icon on the top of the page.
switch:
  - platform: demo
  1. For practice, add a demo platform to your configuration by copying and pasting this YAML into your configuration.yaml file.
  2. Save the changes by clicking or tapping the save icon on the top of the page.

Check Your Configuration

After making any changes to your YAML files, save and navigate back to the Check Configuration tool. The Check Configuration tool can be found in the Server Controls section of the Configuration tab.

If the configuration is valid, you can scroll down to restart Home Assistant. If the configuration is not valid, check your changes for formatting or spelling errors. Do NOT restart Home Assistant with an invalid configuration.
  1. If the configuration is valid, you can scroll down to restart Home Assistant. If the configuration is not valid, check your changes for formatting or spelling errors. Do NOT restart Home Assistant with an invalid configuration.
    • Restarting with an invalid configuration can cause issues that can keep Home Assistant from booting up properly.
Just under the server reset link, there is this list with different aspects of your YAML configuration displayed. When making changes to your YAML files that match these items, you don't need to reset the whole server. Since integrations is not one of the options, you will need to reset the whole server, but this list will come in handy as you get more proficient with Home Assistant.

Just under the server reset link, there is this list with different aspects of your YAML configuration displayed. When making changes to your YAML files that match these items, you don’t need to reset the whole server. Since Integrations is not one of the options here, you will need to reset the whole server, but this list will come in handy as you get more proficient with Home Assistant.

When you choose to restart Home Assistant, you will be prompted to confirm your choice.
After you begin the restart, you will notice that Home Assistant has lost connection. This is normal and will connect again after booting up.
  1. When you choose to restart Home Assistant, you will be prompted to confirm your choice.
  2. After you begin the restart, you will notice that Home Assistant has lost connection. This is normal and will connect again after booting up.
After you restart, any changes you made to the configuration will now take effect. Here you can see your demo switches have taken effect
  1. After you restart, any changes you made to the configuration will now take effect. Here you can see your demo switches have taken effect.
    • You may notice they have different types of controls. The AC entity, has a toggle switch, while the Decorative Lights has separate on and off buttons. Typically, you will see toggle switches for devices that can report their state back to Home Assistant like WiFi connected thermostats or smart plugs. You will see the individual on and off switches for devices that only communicate one way, like RF plugs and IR devices.
  2. The demo switches won’t control anything, they were used to demonstrate how to configure a component. You can safely delete this configuration from your file. After deletion, remember to check your configuration before restarting Home Assistant.

Conclusion

When getting started with configuring Home Assistant, it will benefit you to take your time. Going slowly when setting up your system will help you avoid messing up your configuration files. At first, it can be hard to type things in properly and to format the YAML files correctly. Try not to let it discourage you. You will adapt quickly.

One thought on “Configure Home Assistant

  • April 21, 2023 at 12:36 am
    Permalink

    Very nice instructions for the basic configuration.yaml.

    But what about specific config?like brightness, duration? How do you know where to place that configuration? Some thing like:
    alias: State Reset
    description: ”
    trigger:
    – platform: state
    entity_id: binary_sensor.master_bath_motion_zone
    from: ‘off’
    to: ‘on’
    condition:

    This is part of a config to set the motion detection for an aqara motion sensor to 15 sec. Would you place this in the configuration.yaml?

    Reply

Leave a Reply