# Node-red-contrib-tuya-smart-device across VLANs

**URL:** <https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703>\
**Category:** General\
**Tags:** security, networks\
**Created:** [17 August 2025 06:22 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703 "2025-08-17T06:22:29Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sirhc](https://avatars.discourse-cdn.com/v4/letter/s/b77776/32.png) [@Sirhc](https://discourse.nodered.org/u/Sirhc)\
**Post date:** [17 August 2025 06:22 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/1 "2025-08-17T06:22:29Z")

</div>

Hi All

I have put all of my tuya devices on a separate VLAN. I can ping the devices from the nodered VLAN, but I get an error connecting to the devices on the other VLAN using Node-red-contrib-tuya-smart-device.

Keep getting a findDevice(): Cannot find the deivce error in the console.

Is there a trick with this? I am using an OMADA setup.

---

<div class="post-metadata">

**Author:** ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)\
**Post date:** [17 August 2025 06:31 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/2 "2025-08-17T06:31:59Z")

</div>

Hi @Sirhc

Can you connect to a device, if it's on the same vLAN?  
I don't use tuya, but have an IoT vLAN setup (I dont allow my IoT devices to phone home), and have no issue.

Are you blocking internet access on the tuya vLAN?

---

<div class="post-metadata">

**Author:** ![Sirhc](https://avatars.discourse-cdn.com/v4/letter/s/b77776/32.png) [@Sirhc](https://discourse.nodered.org/u/Sirhc)\
**Post date:** [17 August 2025 06:34 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/3 "2025-08-17T06:34:30Z")

</div>

Yes on the same VLAN I can, yes they can connect to the internet.

I think it has something to do with Tuya find() and not being able to allow the broadcast across VLANs, but I’m struggling to find out how to allow it!

---

<div class="post-metadata">

**Author:** ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)\
**Post date:** [17 August 2025 06:35 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/4 "2025-08-17T06:35:37Z")

</div>

OK, that helps.

I dont use OMADA, but Unifi.  
In OMADA - can you allow MDNS broadcasts between the 2 subnets?

---

<div class="post-metadata">

**Author:** ![Sirhc](https://avatars.discourse-cdn.com/v4/letter/s/b77776/32.png) [@Sirhc](https://discourse.nodered.org/u/Sirhc)\
**Post date:** [17 August 2025 06:38 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/5 "2025-08-17T06:38:11Z")

</div>

I didn’t think Tuya uses mDNS? I can, but not sure how to allocate/setup the “Bonjour Service”

---

<div class="post-metadata">

**Author:** ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)\
**Post date:** [17 August 2025 06:43 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/6 "2025-08-17T06:43:30Z")

</div>

In Unifi, you select which networks, can see each others broadcasts.

Without knowing OMADA - maybe try and find an area that manages this?  
also not using Tuya, but they may send out beacons, which is used to exchange metadata, and achieves the communication - this is all just guess work.

Tuya devices themself may be stopping traffic from subnets its not apart of - for security reasons?

 ![Screenshot 2025-08-17 at 07.40.48](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/6/069518223a6ad029b4b0287fe887dacf7ae00107.png)

---

<div class="post-metadata">

**Author:** ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)\
**Post date:** [17 August 2025 06:46 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/7 "2025-08-17T06:46:19Z")

</div>

> **[How to Configure mDNS on the Omada Controller | TP-Link United Kingdom](https://www.tp-link.com/uk/support/faq/3723/)**
>
> This article tells how to configure the mDNS repeater using Omada SDN Controller v5.6 or above version via Settings \> Services \> mDNS \> Create New Rule.

---

<div class="post-metadata">

**Author:** ![Sirhc](https://avatars.discourse-cdn.com/v4/letter/s/b77776/32.png) [@Sirhc](https://discourse.nodered.org/u/Sirhc)\
**Post date:** [17 August 2025 06:47 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/8 "2025-08-17T06:47:50Z")

</div>

Yeah I have done that a hundred times, tried gateway and AP type, selected all under bonjour service. No luck ☹

---

<div class="post-metadata">

**Author:** ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)\
**Post date:** [17 August 2025 06:54 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/9 "2025-08-17T06:54:26Z")

</div>

Try allowing UDP traffic on 6666 & 6667 between the 2 subnets?  
This seems to be the ports used for broadcast

OMADA, may allow forwarding to different vLANs on these ports

> <https://github.com/rospogrigio/localtuya/issues/1507#issuecomment-1771320896>
>
> Hi,
> 
> All my IoT devices are in a separate VLAN (172.xxx)and the home assistant… is in my main LAN (192.xxxx) and my router (mikrotik routes everything).
> 
> Eveything works in my network works from the IoT to LAN and vice-versa. But when trying to auto add a new device via the Local Tuya, it does not show anything.
> 
> I changed a device to my LAN and the Local Tuya was able to show it.
> 
> Is there anything I can do to use the auto feature?

Its all I have I am afraid 🤷‍♂️

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [17 August 2025 12:43 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/10 "2025-08-17T12:43:25Z")

</div>

This really isn't a node-red question but rather a networking question.

For 2 vlan's to talk, you need a ROUTE between them. But if you route between vlan's there is a decent chance you are breaking the reason for having vlan's in the first place - isolating network traffic.

So it would often be poor practice to do this.

If you really do need to, you should have a firewall set up between the 2 so that you can limit traffic as indicated by Marcus. A lot of routers that support VLAN configurations will let you - or even make you - have firewall configurations between them. As on my Ubiquiti EdgeRouter Lite.

VLAN's are separate networks by design and should be treated as such with appropriate security between them.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [15 November 2025 12:44 UTC](https://discourse.nodered.org/t/node-red-contrib-tuya-smart-device-across-vlans/98703/11 "2025-11-15T12:44:18Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
