Tasmota community integration, free and open source

Control your Tasmota devices locally over MQTT or HTTP: relays, lights, energy, sensors.
Control your Tasmota devices from Gladys, 100 % locally: plugs, relays, bulbs and LED strips, dimmers, shutters, fans, energy meters and sensors. No cloud.
What you get
- Automatic discovery over MQTT (
LWT,Status 0and the Tasmota native discovery) and over HTTP (a list of addresses, or a scan of an IP range). - Every device is identified by its MAC address: renaming it, changing its topic or its IP, or moving it from HTTP to MQTT keeps the same Gladys device and its history.
- Relays (
POWER1…POWER8), lights (on/off, brightness, RGB color, white temperature, effects and their speed), fans (FanSpeed), shutters (open / close / stop, position). - Energy metering: power, apparent and reactive power, voltage, current, energy today, yesterday and total (the total is a cumulative index, usable by the Gladys energy monitoring), multi-channel meters included.
- Sensors: temperature, humidity, pressure, illuminance, CO2, VOC, PM2.5 / PM10, distance, UV index, soil moisture, analog inputs, pulse counters, switch inputs, chip temperature, Wi-Fi signal and uptime.
- Scene triggers: button pressed (single, double, triple… hold), switch input changed, RF code received (Sonoff RF Bridge), IR code received, device online / offline.
- Scene actions: send any Tasmota command (Backlog, RfSend, IRSend, Rule…), turn a relay on for a while, make a light blink, restart a device.
- Dashboard widgets: fleet overview, device card, energy card.
- A "Local" badge on each device, orange when the broker is down and commands fall back to HTTP, red when the device is unreachable.
Choose how the devices talk to Gladys
The Configuration screen starts with Step 1 — Connection mode, followed by three blocks. Gladys shows every block at once: fill in only the block of the option you chose, the others are ignored and can stay empty. The status at the top of the screen always says which option is active and what is missing.
| Connection mode | Fill in | You need |
|---|---|---|
| Option 1 — My existing MQTT broker | block 1 | the address and credentials |
| Option 2 — Dedicated broker deployed by Gladys | block 2 | nothing (optional password) |
| Option 3 — No MQTT, HTTP only | block 3 | the IP addresses of the devices |
Option 1 — My existing MQTT broker
For instance the broker of the Gladys MQTT integration, which already runs on the Gladys host (port 1883, with the user and password shown on the page of that integration).
- Connection mode: Option 1 — My existing MQTT broker.
- Block 1 — Broker URL:
mqtt://<IP of the broker>:1883— use the LAN IP address, notlocalhost(the integration runs in its own container). - Block 1 — Broker user and Broker password, then save.
- On each Tasmota device: Configuration → MQTT, enter the same host, port, user and password.
Option 2 — Dedicated broker deployed by the integration
- Connection mode: Option 2 — Dedicated broker deployed by the integration.
- Block 2 — Password of the devices: optional, leave it empty to have one generated.
Save: the integration starts its own Mosquitto container; block 2 shows the address and
port the devices must use (user
tasmota). - Run the Option 2 — Get the command for the devices action (type the IP address of
Gladys): it gives a ready-to-paste line, e.g.
Backlog MqttHost 192.168.1.10; MqttPort 41883; MqttUser tasmota; MqttPassword …. - Paste it in the Console of each Tasmota device. The device restarts and appears in Gladys.
MQTT topics (options 1 and 2)
Keep %prefix%/%topic%/, the Tasmota default, unless you changed the Full Topic of your
devices to %topic%/%prefix%/.
Option 3 — No MQTT, HTTP only
- Connection mode: Option 3 — No MQTT, HTTP only.
- Block 3 — HTTP addresses:
192.168.1.20, 192.168.1.30-45(or use the Scan an IP range action). - Web user (
admin) and Web password: only if a web admin password is set on the devices. The devices are read every HTTP refresh interval seconds (30 by default).
Block 3 also works with options 1 and 2, for the few devices that do not use MQTT. A device found over HTTP that later connects to the broker switches to MQTT by itself; the Move a device to MQTT action sends it the broker settings for you.
Add the devices
Open the Discovery tab of the integration: the devices found appear there, with their features. Click Add, choose the room, done. When a device gains a feature (a sensor plugged in, a new firmware), an Update button appears.
Actions of the Configuration screen
- Test the connection — broker state and number of devices online.
- Option 2 — Get the command for the devices — the console line for the dedicated broker.
- Add an HTTP device / Scan an IP range — find devices over HTTP (1024 addresses max).
- Identify a light — the light blinks twice and goes back to its state. Relays never blink (they may drive a heater).
- Send a command — any Tasmota command, the answer is shown under the button.
- Restart a device.
- Move a device to MQTT — sends
MqttHost,MqttPort,MqttUser,MqttPassword.
Scenes
Under the Integrations category of the scene editor (Gladys 5.1 or later):
| Trigger | Tasmota setting needed | Variables |
|---|---|---|
| Tasmota button pressed | SetOption73 1 (buttons decoupled from the relays) | button, action |
| Tasmota switch input changed | SetOption114 1 (switches decoupled from the relays) | switch, action |
| RF code received | an RF Bridge (RfReceived) | code, rf_key |
| IR code received | an IR receiver (IrReceived) | code, protocol |
| Tasmota device online / offline | none (LWT over MQTT, failed polls over HTTP) | status |
Every filter is optional: left empty, it matches everything. Read the values in the next actions
with {{triggerEvent.data.code}}, for instance.
Actions: Send a Tasmota command (outputs answered and response), Turn a relay on for a
while (the device turns it off by itself, up to 360 s), Make a Tasmota light blink,
Restart a Tasmota device.
The states themselves (a relay, a temperature…) are regular device features: use the standard "Device state" trigger and "Control a device" action of Gladys for them.
Dashboard
- Tasmota devices — devices count, online and offline, broker connection, state of each device, a Refresh button.
- Tasmota device — pick a device: its main live values, IP, firmware, Wi-Fi signal, uptime, and Toggle, Identify (lights) and Restart buttons.
- Tasmota energy — pick a metering device: 24-hour power chart, live power, voltage, current, energy today, yesterday and total.
Troubleshooting
- Nothing in Discovery (MQTT): check the broker URL uses the LAN IP, and that the devices show "MQTT connected" in their console. Click Scan in the Discovery tab: every known device is asked its status again.
- A device asks for a password (HTTP): fill the Web user and password in the configuration, or in the fields of the Add / Scan actions.
- Buttons do not trigger scenes: send
SetOption73 1to the device (andSetOption114 1for switch inputs). - Logs: open the integration logs from Gladys; set
LOG_LEVEL=debugfor the full detail.
Configuration settings
These are the settings Tasmota asks for in its configuration screen in Gladys.
| Setting | Type | Required | Description |
|---|---|---|---|
| Step 1 — Choose how your devices connect | section | No | Option 1: you already have an MQTT broker (for instance the one of the Gladys MQTT integration): fill in block 1 with its address and credentials. Option 2: you have no broker: the integration deploys a dedicated Mosquitto container, fill in block 2 only. Option 3: no MQTT, the devices are read over HTTP: fill in block 3 only. The blocks of the other options are ignored, you can leave them empty. |
| Connection mode | select | Yes | |
| Block 1 — My existing MQTT broker (option 1 only) | section | No | The address and credentials of your broker. With the broker of the Gladys MQTT integration: mqtt://<IP of Gladys>:1883 and the user and password shown on the page of that integration. Use the LAN IP address, not localhost: the integration runs in its own container. Your Tasmota devices must point to the same broker (Configuration > MQTT on each device). |
| Broker URL | string | No | |
| Broker user | string | No | |
| Broker password | secret | No | |
| Block 2 — Dedicated broker deployed by the integration (option 2 only) | section | No | Nothing to install: when you save, the integration starts its own Mosquitto container. Your devices connect to {{gladys_host}}, port {{port:mqtt}}, user tasmota, with the password below (leave it empty to have one generated). Then run the "Get the command for the devices" action: it gives the line to paste in the console of each Tasmota device. |
| Password of the devices | secret | No | Optional: leave empty to have one generated. |
| MQTT topics (options 1 and 2) | section | No | Keep the default unless you changed the Full Topic of your devices. |
| Tasmota FullTopic | select | Yes | |
| Block 3 — HTTP devices (option 3, optional with options 1 and 2) | section | No | Devices read over HTTP, every few seconds. Required with option 3; with options 1 and 2, only for devices that do not use MQTT. List their addresses (or use the "Scan an IP range" action). Web user and password: only if a web admin password is set on the devices. |
| HTTP addresses | string | No | IPs, host names or ranges, separated by commas. |
| Web user | string | No | |
| Web password | secret | No | |
| HTTP refresh interval (s) | number | No | How often HTTP devices are read (MQTT devices push their changes). |
How to install Tasmota in Gladys
- In Gladys, open Integrations: Tasmota appears in the catalog, next to the native integrations, with a community badge.
- Click Install. Gladys pulls the Docker image (
ghcr.io/gboulvin/gladys-tasmota:1.0.2), starts it in a sandbox isolated from the core, and generates the integration's interface (devices, discovery and configuration). - Open the Configuration screen of the integration, fill in the settings, and save.
- You can also install it directly from its repository URL: https://github.com/gboulvin/Gladys-Tasmota.
Tasmota requires Gladys >=5.1.0. The catalog inside Gladys refreshes every hour, so a new version becomes available at most one hour after its release.
Not running Gladys yet? It is free and open source: follow the installation guide to get started.
About external integrations
Tasmota is an external integration: a community integration packaged as a Docker container and published on GitHub, that Gladys installs in one click and runs in a sandbox isolated from its core. It is published and maintained by gboulvin, not by the Gladys core team.
- Browse all integrations, native and community
- Build and publish your own external integration
- Source code on GitHub — source of this documentation