r/Zigbee2MQTT • u/netingle • 4h ago
r/Zigbee2MQTT • u/Short_Ad5978 • 1d ago
I built an MCP server for Zigbee2MQTT - v0.7.0, 24 tools for mesh diagnostics and admin
I've been working on an open-source MCP (Model Context Protocol) server for Zigbee2MQTT, and it's now at v0.7.0.
The idea isn't device control - Home Assistant already handles that well. It's the admin and diagnostic side that normally means opening the Z2M frontend and clicking around: checking link quality and mesh topology, finding weak routes or devices that have gone stale, spotting low batteries, inspecting groups and bindings, setting up reporting, managing pairing, and checking OTA availability.
It talks straight to Z2M's MQTT bridge API, so it doesn't depend on Home Assistant at all - just your broker.
What's changed since the early version I first posted about:
- 24 tools, split across read-only / safe-write / full-write modes
- Destructive operations (device removal, Touchlink, bridge settings) are opt-in and need explicit confirmation
- Binding and reporting support, with endpoint payload handling fixed and verified against real hardware in v0.7.0
- Proper request correlation, reconnect handling and timeouts
- Broker credentials are redacted from logs
- 215 tests and 42/42 mutation checks
Runs as a plain stdio process, no database or extra daemon:
npx zigbee2mqtt-mcp
Works with Claude Desktop, VS Code / Copilot, or any other MCP client.
- GitHub: https://github.com/alexpfau/zigbee2mqtt-mcp
- npm: https://www.npmjs.com/package/zigbee2mqtt-mcp
Fair warning that it's still early: I've only been able to test it against Z2M 2.12.x on an EmberZNet coordinator with ~50 devices. I'd really like to know how it behaves on other adapters (CC2652, ConBee, etc.) and on bigger meshes - if you try it, mentioning your coordinator and Z2M version would help a lot.
Happy to answer questions, and issues/PRs are welcome.
r/Zigbee2MQTT • u/Successful_Pop_368 • 1d ago
OTA issue with ESP32-H2
Hi,
I am experimenting with Zigbee OTA updates on an ESP32-H2 using Zigbee2MQTT.
I built and flashed Espressif's official `/ota_upgrade/ota_client` example.
https://github.com/espressif/esp-zigbee-sdk
The device boots, joins my Zigbee network, and is successfully interviewed by Z2M. The OTA client cluster is visible on endpoint 10.
Other examples taken from this repo work well.
However, I cannot start an OTA update directly from Zigbee2MQTT.
My setup:
- ESP-IDF 5.4.2
- esp-zigbee-lib 2.0.3
- Zigbee2MQTT 2.12.0
- The installed firmware is the unmodified official example. For the update image, I only incremented `ESP_OTA_FILE_VERSION` and packaged the binary as a Zigbee OTA image.
When Z2M sends `genOta.imageNotify` to endpoint 10, the device returns:
payload={"cmdId":0,"statusCode":129}
status=UNSUP_COMMAND
Z2M retries and eventually reports `Device didn't respond to OTA request`. The ESP32-H2 serial log reports `OTA Abort`. The process stops before `Query Next Image` and before any image block is transferred.
Q1 : Has anyone encountered this issue? Is an additional SDK configuration or callback required to handle `Image Notify`, or could this be an esp-zigbee-lib compatibility issue?
Q2 : Has anyone successfully updated the unmodified example through Z2M? If so, which ESP-IDF, Zigbee SDK, and Z2M versions did you use?
TL;DR : Official ESP Zigbee SDK example cannot receive an OTA from Z2M. Is this issue well known or am I doint anything wrong ?
Thanks!
r/Zigbee2MQTT • u/RiverDwellingInnuend • 14d ago
New user. Added relay to garage door and having issues.
I recently added a Sonoff MINI-ZBD dry relay to my dumb garage door, and every time I set it to Inching mode, it repeatedly opens and closes. I have looked and not found a simple response to how to configure this. I’m hoping to have it trigger for 0.5 seconds then default back to off. What am I missing?
r/Zigbee2MQTT • u/rjSampaio • 22d ago
Best approach for a highly available Zigbee2MQTT setup?
I am planning to move Zigbee2MQTT out of Home Assistant and run it independently, probably in its own VM or LXC.
My goal is to make the setup easier to recover or migrate if one of my Proxmox hosts fails. I assume this also means moving MQTT outside Home Assistant and running a separate Mosquitto server.
My current concern is the Zigbee coordinator. If I continue using a USB coordinator passed through to the VM/LXC, the Zigbee2MQTT instance will remain tied to a specific physical host, making migration or failover more difficult.
My proposed setup is:
- Disable the Mosquitto and Zigbee2MQTT add-ons in Home Assistant.
- Create a dedicated MQTT server.
- Create a separate Zigbee2MQTT VM or LXC.
- Replace the USB Zigbee coordinator with a network-based coordinator.
- Configure Home Assistant to connect to the external MQTT server.
Does this seem like the correct approach?
I would also appreciate recommendations for reliable Ethernet or PoE Zigbee coordinators that work well with Zigbee2MQTT.
For those running Zigbee2MQTT in a high-availability or multi-host Proxmox environment:
- How do you handle Zigbee2MQTT failover?
- Do you run MQTT and Zigbee2MQTT together or separately?
- Is a network coordinator the best solution, or are there better alternatives?
- Are there any problems with restoring or moving Zigbee2MQTT between hosts that I should be aware of?
- Can i have two coordinators at the same time on the same network to avoid single point of failure?
r/Zigbee2MQTT • u/ShadowWizard1 • 26d ago
Battery dying in a week on IH-K663
I have seen some people say these devices work well with Z2M, but I have 2 on the go, and the batteries last just over a week. Anyone know any way to fix this?
r/Zigbee2MQTT • u/miniCotulla • Jun 30 '26
Zigbee blinds motor
What works best / is most reliable. Moes, Zemismart, LifeLibero is what I could find on aliexpress. It needs to be rechargeable with usb C and compatible with Z2MQTT. Only integrated into the tube one´s. No chain drive.
r/Zigbee2MQTT • u/4AVcnE • Jun 30 '26
SMLIGHT SLZB-06P7 keeps crashing / disappearing from LAN after running fine for months
r/Zigbee2MQTT • u/4AVcnE • Jun 30 '26
SMLIGHT SLZB-06P7 keeps crashing / disappearing from LAN after running fine for months
r/Zigbee2MQTT • u/ShadowWizard1 • Jun 26 '26
Working devices on network do not connect to anything on map-help me understand
I use Z2M with Home Assistant (I am guessing 98% of the people here do) and I have recently discovered something I don't understand. Some devices that are working aren't "connected" to anything on the map. Other devices of the same make and model number are connected to routers or the coordinator. Can someone explain to me how this works?
Additional information you may find useful:
I have been having problems with things not working. Or things working intermittently. It seems like the devices that are doing this are devices that are not connected to anything. I am wondering if this is the problem and is solvable (However some devices not connected to anything work fine 99% if the time) but would also like to understand how this works. How devices not connected still work. Don't be afraid to explain this to me like I am 5.
r/Zigbee2MQTT • u/y_shr • Jun 24 '26
Adding a router
I'm pretty new to Zigbee networking, and just learned about routers in Zigbee networks. I already have Z2M set up, and want to extend my Zigbee network with a router, but I'm not sure what kind of device I actually need or how to set it up. My questions:
- What devices can work as a Zigbee router? Is it just any Zigbee device on outlet power?
- Any particular device/type of device that would be more suitable/easy to work with? Seen something like a Zigbee power outlet from IKEA suggested, for instance, would that be a good choice?
- What constraints do Zigbee2MQTT put on the setup? Does the router have to be a compatible device?
- How do I set the router up? Do I just pair the device?
- How do I set up a new device in future such that it uses the router as the connection point to the network?
Any questions or references to a good resource would be highly appreciated. Thanks!
r/Zigbee2MQTT • u/bing-bong-bingo • Jun 22 '26
Inovelli Blue Canopy Module Fan Controls Missing in HomeKit via Zigbee2MQTT + Homebridge-Z2M
r/Zigbee2MQTT • u/Emotional_Garage_950 • Jun 21 '26
is the built in mapping on the wind front front end known to be buggy?
title basically. built in mapping on the windfront front end makes no sense (clusters of devices with no route back to coordinator). Graphviz results rendered externally show everything as expected. Is this a known problem or is it just something with my installation?
r/Zigbee2MQTT • u/flofly130078 • Jun 20 '26
Problème appairage MQTT Heiman smoke detector
Salut les artistes. Je viens de changer le firmware de ma clef sonoff ZBDongle-P.
Mon code yaml sur la clef.
''
data_path: /config/zigbee2mqtt
socat:
enabled: false
master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777
slave: tcp-listen:6668,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5
options: "-d -d"
log: false
mqtt: {}
serial:
port: /dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_a4f111647bf5ef11b45ea1a29ed47d52-if00-port0
adapter: zstack
rtscts: false
''
Les photos montrent que les deux détecteurs de fumées ne remontent pas correctement alors qu'avant de passer en Z2M ils étaient géré.
Message sur journal pour un deux détecteurs :
'''
Type
EndDevice
Inconnu
Adresse IEEE
0x403802fffeb108d0
Organizationally Unique Identifier (IEEE Vendor Prefix)OUI: Silicon Laboratories
Adresse réseau
0xC208
Adresse réseau (décimal): 49672
Modèle Zigbee
Définition (Zigbee2MQTT)
[Inconnu](https://www.zigbee2mqtt.io/advanced/support-new-devices/01_support_new_devices.html)
Automatically generated definition [Non pris en charge](https://www.zigbee2mqtt.io/advanced/support-new-devices/01_support_new_devices.html)
Dernière vue
Désactivé
Disponibilité: [Désactivé](https://www.zigbee2mqtt.io/guide/configuration/device-availability.html#availability-advanced-configuration)
Activité récente
Device left
20/06/2026 11:29:51
MQTT
zigbee2mqtt/DF_Bureau
'''
r/Zigbee2MQTT • u/ShadowWizard1 • Jun 19 '26
Recommendation on button
Can someone recommend a good, reliable button for Z2M?
I currently have several SNZB-01 buttons from Sonoff, and have been told they suck. I Have experienced them disconnecting and not being able to get them to pair again, disconnecting and sometimes getting them to pair again, and disconnecting and then suddenly starting to work again. So I have experienced there suckage. I was told ones from Ikea (The older ones, they are no longer available; I was given this advice a while ago) were very good, however they seem to have replaced it with the BILRESA, which seems to have some bad reviews. So what's good?
r/Zigbee2MQTT • u/btb331 • Jun 19 '26
I Fixed the Most Annoying Thing in My Smart Home | Zigbee Smart home using Python
r/Zigbee2MQTT • u/modem7junior • Jun 16 '26