Choose ESPHome when you want YAML-compiled firmware and direct native Home Assistant integration for custom sensors, relays, or Bluetooth proxies. Choose Tasmota when you want a precompiled binary with a built-in Web UI, JSON pin templates, and MQTT control without compiling code. Choose WLED for addressable LED strips that need segments, presets, and lighting protocols. Choose Zigbee (via ZHA or Zigbee2MQTT) for battery-powered sensors and low-power mesh networks that should not depend on Wi-Fi.
Evidence and limits: This comparison uses the official ESPHome 2026.11.1, Tasmota, WLED, Home Assistant, and Zigbee2MQTT documentation checked on 2026-11-26. The setup steps were not tested on hardware for this guide.
Architecture comparison at a glance
ESPHome, Tasmota, and WLED are firmware tools for microcontrollers. The Zigbee setups below use a 2.4 GHz mesh managed by a dedicated coordinator radio. Radio support varies by chip. The ESP32-C6, for example, has both Wi-Fi and an 802.15.4 radio. ESPHome ESP32 platform · Home Assistant ZHA
| Dimension | ESPHome | Tasmota | WLED | Zigbee (ZHA / Zigbee2MQTT) |
|---|---|---|---|---|
| Setup model | YAML compiled into custom C++ firmware | Precompiled binary configured in a Web UI | Precompiled LED firmware flashed via web installer | Coordinator radio plus paired mesh devices |
| Typical hardware | ESP32 variants, ESP8266, RP2040, BK72xx, RTL87xx, LN882H | ESP8266, ESP8285, ESP32 | ESP32 (recommended) or ESP8266 | One Zigbee coordinator, mains routers, battery end devices |
| Network in this setup | Local IP network over Wi-Fi (ESP32 radios) | Home Wi-Fi, with MQTT to a broker (Wi-Fi setup · MQTT setup) | Home Wi-Fi (WLED Quick Start) | Separate Zigbee mesh through a coordinator. Zigbee2MQTT connects the host to an MQTT broker (ZHA · Zigbee2MQTT) |
| Home Assistant link | Native TCP API with optional encryption (default port 6053) or optional MQTT (Native API · MQTT client) | Official Tasmota integration over MQTT (SetOption19 0, Tasmota 9.2 or later, excluding tasmota-lite.bin) (requirements) | Native WLED integration via auto-discovery or manual hostname/IP (WLED 0.14.0+) (requirements) | Built-in ZHA integration or Zigbee2MQTT via MQTT Discovery (ZHA · MQTT Discovery) |
| On-device logic | Compiled YAML automations | Rules engine, plus Berry scripting on ESP32 | Segments, presets (/presets.json), lighting protocols | Zigbee bindings between supported devices or groups |
| Battery sensor fit | Supports deep_sleep on supported platforms | Sleeping battery end devices |
ESPHome for compiled YAML and custom Home Assistant nodes
As covered in the Home Assistant ESPHome Integration and ESPHome Command Line Interface documentation, ESPHome turns YAML configuration files into custom firmware binaries for supported microcontrollers. You can validate configurations, compile firmware, and upload builds with the command-line tool.
On the hardware side, ESPHome supports the ESP32 family (including esp32, esp32s2, esp32s3, esp32c2, esp32c3, esp32c6, esp32h2, and esp32p4), ESP8266, and RP2040. Its MQTT client also supports BK72xx, LN882H, and RTL87xx platforms. Home Assistant’s ESPHome integration can discover nodes over mDNS and use Noise encryption when enabled. ESPHome boards can act as Bluetooth proxies. ESP32 variants · MQTT platforms · Home Assistant ESPHome integration
Core ESPHome CLI workflow
Start with the ESPHome wizard to generate the node configuration. ESPHome CLI
esphome wizard living_room_node.yaml
Native API versus MQTT and deep sleep configuration
By default, ESPHome’s api: component listens on TCP port 6053 and sets reboot_timeout to 15min. If you enable the mqtt: component (default port 1883 without TLS) and do not connect a native API client, remove the api: block or set its reboot_timeout: 0s. With the default API timeout, the device reboots after 15 minutes without an API client connected. The timer counts a client only after authentication completes. ESPHome Native API · ESPHome MQTT client
Edit the generated living_room_node.yaml using the block for your setup before running validation or compilation. For the encrypted Native API option, update the existing api: block if present and replace YOUR_ENCRYPTION_KEY_HERE with a 32-byte base64-encoded key. The Native API documentation can generate a key. For the MQTT-only option, replace <BROKER_ADDRESS> with the host of your broker. ESPHome Native API · ESPHome MQTT client
# Option A: Native API for Home Assistant
api:
port: 6053
encryption:
key: "YOUR_ENCRYPTION_KEY_HERE"
# Option B: MQTT-only node (use this block on its own)
mqtt:
broker: <BROKER_ADDRESS>
port: 1883
After saving the YAML, validate it and compile the firmware. For the first USB upload, connect the board and set --device to its serial port. Replace /dev/cu.SLAB_USBtoUART with the port for your board. ESPHome CLI
esphome config living_room_node.yaml
esphome compile living_room_node.yaml
esphome upload living_room_node.yaml --device /dev/cu.SLAB_USBtoUART
esphome logs living_room_node.yaml
You can also run esphome run living_room_node.yaml to compile and upload in a single command. ESPHome CLI
Once the Native API node is on the network, open its Discovered entry in Home Assistant under Settings → Devices & services. If it does not appear, select Add Integration → ESPHome and enter the device hostname or IP address. Use the same encryption key when prompted. Home Assistant ESPHome setup
ESPHome can run on battery hardware through the deep_sleep: component, which supports ESP8266, ESP32, BK72xx, and nRF52. Specify run_duration for active reporting and sleep_duration for sleep time. ESPHome Deep Sleep
deep_sleep:
run_duration: 10s
sleep_duration: 10min
Two conditions apply to deep_sleep.
- For timed wake-up on ESP8266, connect
GPIO16toRST. On ESP32, wake-up also works on supported RTC pins. - While in deep sleep, the node stops running tasks and does not respond to network traffic or Over-The-Air (OTA) updates. ESPHome Deep Sleep
ESPHome does not require a local web interface, though the optional web_server component adds one. The component uses flash and some memory for each connected client. Check free heap when combining it with many other features on a memory-constrained board. ESPHome Web Server
Who ESPHome suits and who should skip it
- Suits: Home Assistant users who want version-controlled YAML, native API integration with optional encryption, custom multi-sensor pinouts, or ESP32 Bluetooth proxies.
- Skip if: You want to flash one generic binary and reconfigure pins in a browser.
Tasmota for precompiled binaries and Web UI management
Flash a precompiled Tasmota binary for your device’s ESP8266, ESP8285, or ESP32 chip. After flashing, use the built-in Web UI or console to configure the device. Tasmota Getting Started
Onboarding, Templates, and Home Assistant setup
Disconnect mains power before serial flashing. Keep it disconnected while the serial connection is attached or the device case is open. Flash the device with the Tasmota Web Installer in a Chrome-based browser. If you use the access point to configure Wi-Fi after flashing, start with the first step below. Tasmota Getting Started
- Connect to the initial AP: After flashing, power the board and join its Wi-Fi access point named
tasmota_XXXXXX-####. Openhttp://192.168.4.1in a browser and save your home Wi-Fi credentials. Tasmota initial configuration - Map hardware pins with a Template: Open the device’s local IP address in a browser and go to Configuration -> Configure Other. Paste the JSON template for your device into Template, check Activate, and click Save. Tasmota Templates
- Configure MQTT: Enable MQTT Enable under Configuration → Configure Other. In Configuration → Configure MQTT, enter Host, User, and Password. Tasmota uses MQTT 3.1.1 by default and offers MQTT 5.0 as a compile-time option. ESP32 supports MQTT over TLS natively. ESP8266 requires a custom build for TLS. Tasmota MQTT
- Set up Home Assistant discovery. Home Assistant’s Tasmota integration requires an MQTT broker, the Home Assistant MQTT integration, and Tasmota 9.2 or later. The
tasmota-lite.binbuild is excluded. In the Tasmota Web UI, open Tools → Console, typeSetOption19 0in Enter command, and press Return. Home Assistant Tasmota integration LegacySetOption19 1MQTT discovery was removed from Tasmota builds. Tasmota discovery
Use SetOption30 1 in the Console to expose the device’s relays as light entities in Home Assistant. With SetOption30 0, relays appear as switches. Home Assistant Tasmota integration
Local automation with Rules and Berry
Tasmota offers Rules and Berry for local automation.
- Rules. Use event-driven trigger-and-action commands with 16 volatile variables (
Var1toVar16) and 16 variables that persist after reboot (Mem1toMem16). Enable a configuredRule1in the Console. Tasmota Rules
Rule1 1
- Berry scripting (ESP32 only): An embedded, dynamically typed scripting language included in ESP32 Tasmota builds. You can try scripts in Configuration → Berry Scripting Console or use
autoexec.befor scripts that run at startup. Tasmota Berry Scripting
For an over-the-air Tasmota upgrade, use the Web UI or set the upgrade URL with OtaUrl and start the upgrade with Upgrade 1. On Tasmota 8.2 or later, if a file upload reports Upload buffer miscompare, try the .gz binary first. If the same error persists, upload tasmota-minimal.bin or its compressed version, wait for the device to restart, then upload the full build. Tasmota Upgrading
Who Tasmota suits and who should skip it
- Suits: Users flashing compatible ESP devices who want browser-based setup, reusable JSON templates, and MQTT control.
- Skip if: You want to avoid running an MQTT broker for Home Assistant, or you prefer keeping all device configurations as compiled YAML files in source control.
WLED for addressable LED strips and lighting effects
WLED is Wi-Fi lighting firmware for ESP32 and ESP8266 controllers. It targets digital addressable LED strips (including WS2812B, WS2811, SK6812 RGBW, APA102, WS2801, LPD8806, and WS2815) and can also drive non-addressable analog strips with a GPIO and MOSFET for each color channel. WLED Compatible LED Strips · WLED Quick Start
Quick start and hardware sizing limits
- Wire a digital addressable strip. For a strip such as a WS2812B-compatible strip, connect strip power, connect the data line to the GPIO listed for your board below, and join the controller and strip grounds. Check the pinout for your specific board. WLED Quick Start
- Flash WLED and connect to its access point. Use the browser-based installer. After flashing, the first 30 LEDs of an addressable strip light up orange. Join the controller’s
WLED-APnetwork using the default password shown in the WLED Quick Start. - Join your home network. While connected to
WLED-AP, open4.3.2.1in your browser and select Config → WiFi Setup. Enter your home network name and password, set an mDNS name, and click Save & Connect. Reconnect your phone or computer to home Wi-Fi. Open the controller’s.localname in your browser. If you can’t reach it by name, find its IP address in your router’s device list and open that address. WLED Wi-Fi setup
Hardware choice affects how many segments a controller can manage. WLED Segments · WLED Presets
| Resource | ESP32 (recommended) | ESP8266 |
|---|---|---|
| Virtual segments (WLED Segments) | Up to 32 (up to 64 with PSRAM) | Up to 16 |
User presets (/presets.json) (WLED Presets) | Up to 250 | Up to 250 |
| Quick Start data pin for addressable strips | GPIO16 (GPIOs 4, 13, and 16 to 33 also listed) | GPIO2 (labeled D4 on most development boards) |
For boards with less than 4 MB of flash, use the other flashing methods listed in the WLED Quick Start. In WLED, Segment 0 is the main segment by default. WLED Segments Presets in /presets.json can save all configured segments or contain custom HTTP or JSON API commands. WLED Presets
Home Assistant and lighting network protocols
Home Assistant’s native WLED integration requires WLED 0.14.0 or newer. It can auto-discover controllers or accept a hostname or IP address. It exposes lights, per-segment lights when applicable, and controls for configured presets and playlists. Color palettes are available per segment. Home Assistant WLED integration
Beyond Home Assistant, WLED supports MQTT, E1.31 and Art-Net, and DDP realtime streaming. WLED MQTT · WLED E1.31, Art-Net, and DDP
Who WLED suits and who should skip it
- Suits: Anyone driving addressable RGB or RGBW LED strips who wants ready-made effects, multi-zone segments, saved presets, and show-lighting protocols without writing YAML light code.
- Skip if: Your project combines general environmental sensors, relays, or non-lighting hardware on the same board, where ESPHome or Tasmota is a better fit.
Zigbee mesh for battery sensors and low-power networks
The setups in this guide use low-power Zigbee radios in the 2.4 GHz band. The mesh uses a coordinator and can include routers and end devices. Home Assistant ZHA
- Coordinator (one per network): A dedicated radio adapter that connects the Zigbee network to your smart home host.
- Routers. Most mains-powered Zigbee devices act as routers, relaying messages and extending range.
- End devices. Battery-powered examples include door and temperature sensors that can sleep between reports.
ZHA versus Zigbee2MQTT in Home Assistant
Two Zigbee options for Home Assistant are ZHA and Zigbee2MQTT.
- ZHA (Zigbee Home Automation): Built directly into Home Assistant. It connects Home Assistant directly to Zigbee devices through a compatible coordinator. In Home Assistant, go to Settings → Devices & services → Add Integration, select Zigbee Home Automation, and complete the on-screen setup. Then go to Settings → Connectivity → Zigbee → Add device and follow the manufacturer’s factory reset instructions for the device you want to pair. Home Assistant ZHA setup
- Zigbee2MQTT: It runs as a standalone bridge requiring a compatible Zigbee adapter, a host computer, and an MQTT broker such as Mosquitto. Follow the installation instructions for your host platform, then start Zigbee2MQTT. On first launch without
configuration.yaml, open the onboarding page, usually athttp://localhost:8080, and configure the adapter. Use the onboarding URL for your installation if it differs. Allow devices to join before putting your device in pairing mode. Follow the instructions for your model in Supported Devices, or try a factory reset if no instructions are available. Check the log for a successful interview. Zigbee2MQTT Getting Started
To expose Zigbee2MQTT devices automatically in Home Assistant’s device registry, enable Home Assistant’s MQTT integration and add this block to Zigbee2MQTT’s configuration.yaml. Zigbee2MQTT MQTT Discovery
homeassistant:
enabled: true
Mesh deployment and 2.4 GHz interference checklist
Low-power 2.4 GHz Zigbee radios can be affected by nearby electromagnetic interference and overlapping Wi-Fi frequencies.
- Isolate the coordinator from USB 3.x noise. Use a shielded USB extension cable and preferably connect it to a USB 2.0 port. Keep the coordinator away from USB 3.x ports, unshielded USB 3.x devices or cables, and Wi-Fi routers. ZHA interference guidance
- Plan your Zigbee channel before pairing. Zigbee and Wi-Fi can overlap in the 2.4 GHz band. To choose a channel in Zigbee2MQTT, set
channelunderadvanced:inconfiguration.yaml. The documentation recommends ZLL channels11,15,20, or25. Thepan_id,ext_pan_id, andnetwork_keysettings are optional. On an existing network, Zigbee2MQTT supports changing channels only onzstackandemberadapters. Devices that sleep through the update may switch channels when they wake. If a device is still unresponsive several minutes after the change and after you wake it, consider re-pairing it. Zigbee2MQTT channel configuration - Place Zigbee routers for coverage. Keep Zigbee routers relatively close to each other to help extend mesh coverage. ZHA mesh coverage
Who Zigbee suits and who should skip it
- Suits: Battery-powered door and temperature sensors, plus homes that want compatible off-the-shelf Zigbee devices.
- Skip if: You want to build custom microcontroller circuits, run addressable LED strip animations, or avoid buying and maintaining a coordinator radio.
Decision checklist by device type
Use the table to match each project to a stack.
| Project or device | Best-fit choice | Reason |
|---|---|---|
| Custom ESP32 sensor board, multi-relay controller, or Bluetooth proxy | ESPHome | YAML defines connected hardware, and the native API exposes entities in Home Assistant |
| Compatible ESP smart plug or wall switch needing browser setup | Tasmota | Precompiled binary plus JSON templates avoid local compiling |
| Addressable RGB or RGBW LED strip with zones and effects | WLED | Segments, presets, and E1.31/DDP support |
| Battery door or temperature sensors | Zigbee (ZHA or Zigbee2MQTT) | Sleepy sensors can report when triggered. Some end devices communicate through a parent router. (ZHA sleepy devices) |
| Mixed smart home with all four workloads | Combine all four in Home Assistant | Each stack has a native or MQTT Discovery integration in Home Assistant |
Browse the ESPHome Guide post index or find guides by category and tag.
Frequently asked questions
Can ESPHome, Tasmota, WLED, and Zigbee run together in Home Assistant?
Yes. Home Assistant maintains separate native integrations for ESPHome, Tasmota (over MQTT), WLED, and ZHA, and integrates with Zigbee2MQTT through MQTT Discovery. Running all four together lets you keep lighting on WLED, battery sensors on Zigbee, precompiled plugs on Tasmota, and custom ESP builds on ESPHome.
Why not use ESPHome deep sleep for every battery sensor instead of Zigbee?
ESPHome’s deep_sleep component works on ESP8266, ESP32, BK72xx, and nRF52 boards, but a sleeping node ignores all network traffic and OTA updates until it wakes up. On ESP8266, it also requires wiring GPIO16 to RST for timed wake-up. The timed example above wakes the ESPHome node on a schedule to check and report readings. ESPHome Deep Sleep A sleepy Zigbee door sensor can report when triggered over a separate mesh. For example, ZHA describes Xiaomi door sensors that can communicate through a parent router. ZHA sleepy devices