Local energy monitoring and switching for TP-Link Tapo P110 and P115 smart plugs.
- Fully local polling — no cloud API is used during normal operation
- Current power, today's energy and monthly energy sensors
- On/off control directly from Home Assistant
- UI-based setup and configurable polling interval
- One config entry per plug
- KLAP transport on port 80 with individual requests for firmware compatibility
- Automatic one-time session recovery if a plug rejects an expired KLAP session
| Model | Switch control | Current power | Daily energy | Monthly energy |
|---|---|---|---|---|
| Tapo P110 | ✅ | ✅ | ✅ | ✅ |
| Tapo P115 | ✅ | ✅ | ✅ | ✅ |
Other Tapo models have not been validated and are not officially supported.
Some P110/P115 firmware versions — notably P115 firmware 1.4.x — reject batched multipleRequest calls with HTTP 403 after successful authentication. Tapo Energy sends each request separately and explicitly uses KLAP over port 80. This avoids the problematic batched query path while keeping communication local.
- Open HACS in Home Assistant.
- Select the three-dot menu and choose Custom repositories.
- Add
https://github.com/MTTPoll/tapo-energyand select Integration. - Find Tapo Energy in HACS and select Download.
- Restart Home Assistant.
- Go to Settings → Devices & services → Add integration and search for Tapo Energy.
- Copy
custom_components/tapo_energyinto your Home Assistant configuration directory at/config/custom_components/tapo_energy. - Restart Home Assistant.
- Go to Settings → Devices & services → Add integration and search for Tapo Energy.
Enter the plug's local IP address, your Tapo account email address and password. Repeat the setup for every plug you want to add.
In the Tapo app, enable Compatibility with third-party apps for the account used by Home Assistant. Assigning a fixed IP address to each plug in your router is strongly recommended.
The integration polls every 30 seconds by default. Open the integration entry and select Configure to change the interval.
Each plug provides:
| Entity | Unit | Home Assistant class |
|---|---|---|
| Current power | W | Power / Measurement |
| Energy today | kWh | Energy / Total increasing |
| Energy this month | kWh | Energy / Total increasing |
| Switch | On / Off | Switch |
The integration cannot connect
- Verify the plug's IP address and that Home Assistant can reach it on the local network.
- Confirm the Tapo credentials and enable third-party app compatibility in the Tapo app.
- Make sure the plug is online and not isolated from Home Assistant by a guest network or VLAN rule.
Entities are unavailable
Search the Home Assistant log for tapo_energy. Temporary network loss is the most common cause. A fixed DHCP lease helps prevent the plug's address from changing.
Authentication succeeds but requests return HTTP 403
Update the plug to the latest firmware available in the Tapo app. If the problem persists, remove and re-add the plug in the Tapo app to reset its device session.
- Vollständig lokale Abfrage — im normalen Betrieb wird keine Cloud-API verwendet
- Sensoren für aktuelle Leistung sowie Tages- und Monatsverbrauch
- Ein-/Ausschalten direkt aus Home Assistant
- Einrichtung über die Benutzeroberfläche und einstellbares Abfrageintervall
- Ein Konfigurationseintrag pro Steckdose
- KLAP-Transport über Port 80 mit Einzelanfragen für hohe Firmware-Kompatibilität
- Einmalige automatische Sitzungswiederherstellung bei abgelehnter KLAP-Sitzung
| Modell | Schalten | Aktuelle Leistung | Tagesverbrauch | Monatsverbrauch |
|---|---|---|---|---|
| Tapo P110 | ✅ | ✅ | ✅ | ✅ |
| Tapo P115 | ✅ | ✅ | ✅ | ✅ |
Andere Tapo-Modelle wurden nicht validiert und werden nicht offiziell unterstützt.
Einige Firmware-Versionen der P110/P115 — insbesondere P115 Firmware 1.4.x — lehnen gebündelte multipleRequest-Anfragen trotz erfolgreicher Anmeldung mit HTTP 403 ab. Tapo Energy sendet jede Abfrage einzeln und verwendet ausdrücklich KLAP über Port 80. Dadurch wird der problematische Sammelabfrage-Pfad vermieden, während die Kommunikation lokal bleibt.
- HACS in Home Assistant öffnen.
- Im Drei-Punkte-Menü Benutzerdefinierte Repositories auswählen.
https://github.com/MTTPoll/tapo-energyhinzufügen und die Kategorie Integration wählen.- Tapo Energy in HACS suchen und Herunterladen auswählen.
- Home Assistant neu starten.
- Einstellungen → Geräte & Dienste → Integration hinzufügen öffnen und nach Tapo Energy suchen.
custom_components/tapo_energynach/config/custom_components/tapo_energyim Home-Assistant-Konfigurationsverzeichnis kopieren.- Home Assistant neu starten.
- Einstellungen → Geräte & Dienste → Integration hinzufügen öffnen und nach Tapo Energy suchen.
Die lokale IP-Adresse der Steckdose sowie E-Mail-Adresse und Passwort des Tapo-Kontos eingeben. Die Einrichtung für jede weitere Steckdose wiederholen.
In der Tapo-App muss für das verwendete Konto Kompatibilität mit Drittanbieter-Apps aktiviert sein. Eine feste IP-Adresse beziehungsweise DHCP-Reservierung für jede Steckdose wird dringend empfohlen.
Standardmäßig fragt die Integration alle 30 Sekunden neue Werte ab. Über Konfigurieren am Integrationseintrag lässt sich das Intervall ändern.
Jede Steckdose stellt bereit:
| Entität | Einheit | Home-Assistant-Klasse |
|---|---|---|
| Aktuelle Leistung | W | Leistung / Messung |
| Verbrauch heute | kWh | Energie / Fortlaufende Summe |
| Verbrauch im Monat | kWh | Energie / Fortlaufende Summe |
| Schalter | Ein / Aus | Schalter |
Die Integration kann keine Verbindung herstellen
- IP-Adresse prüfen und sicherstellen, dass Home Assistant die Steckdose im lokalen Netzwerk erreicht.
- Tapo-Zugangsdaten prüfen und die Kompatibilität mit Drittanbieter-Apps in der Tapo-App aktivieren.
- Sicherstellen, dass die Steckdose online ist und nicht durch Gastnetz- oder VLAN-Regeln von Home Assistant getrennt wird.
Entitäten sind nicht verfügbar
Im Home-Assistant-Protokoll nach tapo_energy suchen. Meist ist die Steckdose kurzzeitig nicht erreichbar. Eine feste DHCP-Zuweisung verhindert, dass sich ihre IP-Adresse ändert.
Anmeldung erfolgreich, danach HTTP 403
Die Steckdose über die Tapo-App auf die neueste verfügbare Firmware aktualisieren. Bleibt das Problem bestehen, die Steckdose in der Tapo-App entfernen und erneut hinzufügen, um die Gerätesitzung zurückzusetzen.
- Protocol / Protokoll: KLAP, HTTP port 80
- Library / Bibliothek:
python-kasa - Polling / Abfrage:
get_device_infoandget_energy_usageas individual requests - Control / Steuerung:
set_device_info - Update interval / Intervall: 30 seconds by default
Bug reports and pull requests are welcome. Please include the plug model, firmware version and relevant tapo_energy log entries in issue reports.
Fehlerberichte und Pull Requests sind willkommen. Bitte bei Fehlern Steckdosenmodell, Firmware-Version und relevante tapo_energy-Protokolleinträge angeben.
Released under the MIT License. / Veröffentlicht unter der MIT-Lizenz.