Z2MQTT External converter

Unfortunately it’s not working here…

Added the file here:

But after restarting, still got this:

image

What am i missing? Nothing useful in the logs of TZ3000 :frowning:

The /data directory is ~/homeassistant/zigbee2mqtt/. So there is no actual data directory necessary.

2 Likes

You sir, are a hero!

It’s supported now. Now i can debug it further (looks like button actions are missing, but i need to check it further).

Thank you!!!

For orthers:

i put the generated external converter data in:

/homeassistant/zigbee2mqtt/external_converters

1 Like

I’m struggling with this to i created a folder via Terminal zigbee2mqtt/external_converters

but im still getting the error: z2m: Failed to call ‘ExternalConverters’ ‘start’ (node:internal/modules/cjs/loader:645

this is my file structure

Have you restarted Z2M since you created that folder? Also, swat happens if you delete line 6 in your convertor.js (the one with the obvious error)?

I also have this temperature probe. I have never dealt with an unsupported device, so I started reading up on it and came across this thread. I saved my configuration file in /homeassistant/zigbee2mqtt/external_converters (see below), but I don’t see that it is doing anything. Even the z2m logs don’t show any mention of external_converters, so I really don’t think it is even being read. Here’s the file that I saved ts000f.mjs · GitHub

➜  zigbee2mqtt git:(master) ✗ pwd
/homeassistant/zigbee2mqtt
➜  zigbee2mqtt git:(master) ✗ ls -la *
-rw-r--r--  1 root root  1167 Apr 27 09:04 configuration.yaml
-rw-r--r--  1 root root  8086 Apr 27 06:26 coordinator_backup.json
-rw-r--r--  1 root root   980 Dec 17  2022 coordinator_backup.json.saved
-rw-r--r--  1 root root 30227 Apr 27 09:12 database.db
-rw-r--r--  1 root root 10932 Dec 17  2022 database.db.backup
-rw-r--r--  1 root root  2169 Apr 27 09:12 devices.yaml
-rw-r--r--  1 root root    93 Dec 18  2022 groups.yaml
-rw-r--r--  1 root root  6031 Apr 27 09:10 state.json

external_converters:
total 12
drwxr-xr-x 2 root root 4096 Apr 27 08:41 .
drwxr-xr-x 4 root root 4096 Apr 27 09:12 ..
-rwxr-xr-x 1 root root 1123 Apr 27 08:41 ts000f.mjs

I also tried several different “external_converters” in the z2m configuration.yaml file, such as

external_converters:
  - ts000f

external_converters:
  - ts000f.mjs

These give errors in the logs that ts000f or ts000f.mjs could not be found

I also tried
external_converters: []

➜  zigbee2mqtt git:(master) ✗ head configuration.yaml 
external_converters: []
devices:
  - devices.yaml
groups:
  - groups.yaml
homeassistant: true
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
  user: addons

I also tried removing the external_converters altogether, but nothing seems to be happening. Like I said, I don’t see any mention of external converters in the log, and my device still isn’t working

I did see that my vendor/manufacturer seems to be slightly different, so I did update that, but I really think my problem is that the file simply isn’t being read at all.

What version of Zigbee2mqtt are you using? The inclusion of external converters changed between 1.x and 2.x.

Edge:

[11:01:56] INFO: Preparing to start...

[11:01:56] INFO: Socat not enabled

[11:01:56] INFO: Starting Zigbee2MQTT...

Zigbee2MQTT:info 2025-04-27 11:01:58: Logging to console and directory: '/config/zigbee2mqtt/log/2025-04-27.11-01-58' filename: log.txt

Zigbee2MQTT:info 2025-04-27 11:01:58: Starting Zigbee2MQTT version 1.35.1-dev (commit #769bc14)

Zigbee2MQTT:info 2025-04-27 11:01:58: Starting zigbee-herdsman (0.32.3)

Zigbee2MQTT:info 2025-04-27 11:02:02: zigbee-herdsman started (resumed)

Zigbee2MQTT:info 2025-04-27 11:02:02: Coordinator firmware version: '{"meta":{"maintrel":1,"majorrel":2,"minorrel":7,"product":1,"revision":20220219,"transportrev":2},"type":"zStack3x0"}'

Funny thing is, I can’t remember why I am using Edge. I remember doing that many years ago, but right now I don’t remember at all. Good chance I could move to the regular branch if that would help.

Looks like you haven’t updated Z2M in a while. The non-dev branch is at version 2.2.1, while you’re still on 1.35.1.

Are you sure you’re set up correctly for Z2M? The git: (master) in all your logs is…weird. Maybe it’s docker stuff, which I’m not entirely familiar with.

I’ve got 20+ zigbee devices that are working perfectly, but for sure I need to update. I will work on that and then see how things are working. Thanks!!

Hey, that did it! Upgraded to the latest version and I am good to go. Thanks for the help!

1 Like

you need to install the terminal, and enter:

cd /homeassistant/zigbee2mqtt
mkdir external_converters
cd external_converters
nano converter.js and paste the code.

save it and restart z2m

1 Like

I want to tell you that I also got stuck on this (despite, or maybe because of, using an LLM), and your instructions helped me.

On July 22 2025
Using zigbee2mqtt version 2.5.1-1

Trying to get an external converter to load but no success. I’m not seeing any log entries indicating that it is. There’s differing ideas both in the documentation and forums. I think I’ve tried them all but no luck. Even had Grok helping but it’s just guessing and even had me delete the zigbee2mqtt database file. Luckily I had a backup.

  • Should there be a reference to the converter file in the configuration.yaml and where in the hierarchy should it be placed?
  • Where should the converter file be saved? /homeassistant/zigbee2mqtt/data/external_converters, or perhaps, /homeassistant/zigbee2mqtt/external_converters
  • Is it okay to make all these changes with the HA File Editor or should the CLI be used. Also, do you need to be setting file permissions and ownership with the CLI?