This repository provides a complete and ready-to-use configuration for integrating TASMOTA-powered smart switches into Home Assistant. It includes automation examples, MQTT configuration tips, and YAML templates designed to simplify the setup and control of your smart switches.
The goal of this project is to offer energy-efficient, easy-to-configure, and reliable automation for everyday smart home scenarios. Whether you're turning on lights, managing appliances, or just learning how to use TASMOTA with Home Assistant, this repository gives you a solid foundation.
π Features:
Hass-ready YAML scripts for switch control
Automation for device states
MQTT integration setup
Energy monitoring examples
Bulgarian and English support
Flashing SONOFF devices gives you full local control, and the ability to integrate them into Home Assistant ensures you wonβt miss the cloud functionality they originally come with.
![]() |
This is the device I will flash with TASMOTA, and the reasons are: - It takes too long to go from offline to online - Huge delay when switching - Often requires reconfiguration |
---|
Caution
Before proceeding, disconnect the ["Sonoff BasicR2"][sonoff] from the power supply!!!
![]() |
AZDelivery TTL Serial Adapter is the tool that will be used to connect, communicate, and flash the Sonoff BasicR |
---|
Before connecting, you need to install the following drivers: "CP2102 drivers:", "CH342, CH343, CH9102 drivers:", and "CH340, CH341 drivers:". After installation, restart your operating system before proceeding.
Caution
Before continuing, make sure the ["Sonoff BasicR2"][sonoff] is disconnected from the power supply!!!
Note
To connect the ["Sonoff BasicR2"][sonoff] to the ["AZDelivery TTL Serial Adapter"][azd], you will need access to the circuit board of the ["Sonoff BasicR2"][sonoff], meaning youβll have to disassemble it!
Check the wiring diagram in the image below!
πWIRING DIAGRAM
Warning
Note that RX <--> TX are swapped. If you follow the diagram, you wonβt have communication issues with the ["Sonoff BasicR2"][sonoff].
- Tasmota Web Installer - Flash Tasmota using a Chromium-based browser for ESP82xx and ESP32
- Tasmotizer - Flashing and firmware download tool for ESP82xx only. (Windows, Linux, or Mac)
- ESP-Flasher - GUI flasher for Tasmota based on ESPTOOL.py for ESP82XX and ESP32. (Windows, Linux, or Mac)
- Esptool.py - Official flashing tool from Espressif for ESP82xx and ESP32.
Download the latest version of the file named "tasmota.bin"
For this project, I used the Tasmota Web Installer, which doesnβt require manual firmware download. It offers a selection of firmware to choose from:
Installing this add-on is quite easy and is no different than installing any other Home Assistant add-on.
- Click the Home Assistant My button below to open the add-on in your Home Assistant instance.
-
Open the add-on in your Home Assistant instance.
-
Click the "Install" button to install the add-on.
-
Start the "TasmoAdmin" add-on.
-
Check the "TasmoAdmin" logs to see if everything went smoothly.
-
By default, the username is "admin" and the password is "password".
Integration is just as easy. Click the button below:
Note
This integration will fully connect Home Assistant to all devices added via the TASMOTA add-on. Restart Home Assistant and enjoy full control of your devices.
Tip
If you liked this project, you can find more interesting projects made by me HERE.
If you have any difficulties or questions, donβt hesitate to contact me.