Warning: file_put_contents(/home/clients/81b51a55b78a35c5c4c50dd82cac1015/diyprojects/wp-content/uploads/wpo/images/wpo_logo_small.png.webp): failed to open stream: Disk quota exceeded in /home/clients/81b51a55b78a35c5c4c50dd82cac1015/diyprojects/wp-content/plugins/wp-optimize/vendor/rosell-dk/webp-convert/src/Convert/Converters/Gd.php on line 428
Home Assistant. Get started on Raspberry Pi 4. Procedure 2020 • DIY Projects
DIY Projects

Home Assistant. Get started on Raspberry Pi 4. Procedure 2020

Home Assistant 2020 installation procedure on Raspberry Pi 4, Odroid, Intel NUC, SBC Thinkercad, VM Debian

Home Assistant (HASS) is a very powerful and secure home automation server entirely written in Python which has an impressive number of plugins (free!). Getting started may seem more difficult compared to Domoticz, but great efforts have been made to simplify in recent years.


Tutorial updated on June 25, 2020

Previously, it was possible to simply install HASS with a single command line (like most other home automation software). It’s still possible, but it’s best to use a pre-compiled image. Even if things are going in the right direction, getting started with HASS may still seem a bit technical. The multiplication of names first. Core, Supervised … you end up getting lost. On the installation side, nothing too complicated, just the configuration of the WiFi which requires a temporary USB key: roll:

Recommended material

Home Assistant fits very well with an old Raspberry Pi 3 model B, no problem to recycle an old Raspberry Pi lying on the shelf. If you are new to home automation, I advise you to opt for a Raspberry Pi 4 with at least 2GB of RAM. Home Assistant also works very well on Tinkerboard, Odroid-C2, Odroid-N2 (4GB), Odroid-XU4, Intel-Nuc and virtual machines.

Raspberry Pi 4 Kit (best solution)

Purchasing a Raspberry Pi 4 in the form of a bundle remains the most economical solution. The Raspberry Pi 4 heats more than the previous generation, remember to order a cooling system if it is not included in your kit.

See more kits

Quality 5V / 3A power supply

The Raspberry Pi consumes little but it is preferable to have a power supply that can deliver 2.5A minimum. For a Raspberry Pi 4 or the use of the GPIO and / or the camera module requires a USB-C type 5V / 3A power supply (3000mA)

Micro-USB Power supply for Raspberry Pi 3 model A+, B+ or older

See more power supply and UPS HAT

Two class 10 microSD boards

An 8GB SD board is more than enough. Buy a major brand board with the mention class 10 minimum. You will get better performance with new generation SDXC type II V90 boards (90MB/s).

Choosing a quality SD board is crucial. On the one hand so that the system is fast and on the other hand to avoid breakdowns. SD boards were not designed for such intensive use (not like SSD flash drives).

Buy a second SD board and regularly clone the main SD board (after each update, every month). In case of failure, you can restart your server in a few minutes without having to reinstall everything.

See more high performance SDXC II microSD board

Recover HASS image for Raspberry Pi or other nano-PC

Go to this page to retrieve the image that corresponds to your platform. Currently the development team maintains the following images

You can also retrieve the image of the latest release directly on GitHub.

There is no need to decompress the image

Once the image is downloaded, you can use BelanaEtcher or Pi Imager to install the Home Assistant image on the micro-SD board.

1Click the Choose Image button located below Operating System. Scroll to the bottom of the list and choose Use Custom Operating.

2Insert the microSD board into the reader, then click SD Card

3Go to the download folder on your computer and select the previously downloaded HASS image. Start the copy by clicking on Write

The image weighing less than 300MB, the writing operation is very fast. At the end of the operation, the microSD board is automatically ejected.

4If the Raspberry Pi is connected via Ethernet to the local network, you can skip to the First start up step.

WiFi configuration

HASS does not offer any configuration tool for the WiFi connection. You have to go through a small configuration file that you will store on a USB key that you will have to plug in at the first start. It’s a bit special but for the moment it is the solution chosen by the developers. The procedure is detailed in step 4 here (not obvious !!).

1Connect a USB memory stick (or a microSD board). The key must

2Rename the key and format it if necessary.

3Once ready, create a folder called network

4Open a text editor and paste this configuration. Several examples are available here.

5Change your connection parameters:


# Uncomment below if your SSID is not broadcasted




It is possible to assign a fixed IP address by replacing method = auto


6Save the WiFi configuration in the network folder under the name my-network.

7Eject the USB memory stick.

Prepare the Raspberry Pi 4

Before turning on the power, connect the elements as follows:

  1. Connect keyboard and screen (optional)
  2. Insert the micro-SD board on which the Home Assistant image is installed in which board
  3. Network
    • Connect the USB key containing the configuration file (only on first start-up)
    • Or connect the Ethernet cable
  4. Finally turn on the power



Do nothing during startup, this phase lasts about a minute.

Access the administrator interface

Once the startup log no longer displays anything new, you can access the administration interface.

Although (almost) everything can be done from the WEB interface, HASS has a command line administration interface. It is easily accessed by tapping the Enter key on the keyboard.

When the command prompt appears, type root.

There is no password! Just the Enter key. You can modify it from the Web interface later

Retrieve the HASS IP address

Home Assistant broadcasts a machine name which is by default homeassistant. If however you prefer to use the IP address, here is how to retrieve it (in case it has not been assigned manually).

Once connected to HASS, enter the login command to access the system commands then ip a to display the network information.

The IP address is located in the WLAN0 info block.

First start of Home Assistant

At the first start, HASS automatically retrieves the last update. It all depends on your internet speed, but it can take around 20 minutes.

Open a browser and enter http://homeassistant: 8123 or http://IP_HASS: 8123 in the URL.

HASS indicates that the update is in progress.

Once the update is complete, HASS will ask you a few questions.

As you can see HASS is based on the language used by the internet browser to translate the interface into your language (here in french for example). It’s really great !

Provide your name, login (user name) and password

The scenarios can be triggered according to your address, you can configure it later.

HASS itself searches for home automation accessories that you own. You can add others manually. The list is just impressive!

Here it is, Home Assistant is ready!

And now what to do with Home Assistant?

Your home automation box is ready! Here are other tutorials to go further and why not develop your own home automation accessories based on ESP32 or ESP8266.


Click to rate this post!
[Total: 2 Average: 5]
Exit mobile version