logo elektroda
logo elektroda
X
logo elektroda

[Solved] How do I connect a Wi-Fi/Zigbee relay to a 24 V controller and Home Assistant?

sajmon_mówi 2289 13
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #1 21486557
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    Welcome.
    Quick question.

    I will be setting up a controller to illuminate stair treads, the controller has a constant light function via a stair switch.
    The controller is on 24 volts.

    To this I want to connect some kind of Wi-Fi/Zigbee relay so that I can switch on the permanent lighting from Home Assistant.
    Only 1 - there is only 24 V current flowing there, 2 - from one socket goes one cable to the controller, the other to the minus from the power supply and that's it.... And of course between the sockets 2 signal cables.

    How do I figure this out?

    Diagram for connecting a staircase lighting controller with labels.
  • ADVERTISEMENT
  • #2 21486647
    kindlar
    Level 42  
    Posts: 7820
    Help: 912
    Rate: 1603
    The relay does not apply voltage, it just closes the circuit like a switch.
    What do you mean by a Wi-Fi relay? Can you provide a reference for this device?
  • #3 21486681
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    I may have misspoken, I am looking for a device that will allow me to control the lighting from Home Assistant at the stair switches.
  • ADVERTISEMENT
  • #4 21487506
    hindoos
    Level 36  
    Posts: 3637
    Help: 286
    Rate: 652
    If it is as shown in the diagram, i.e. shorting the SW input to GND switches the light, then at its simplest a 'voltage free relay' will suffice, i.e. one that connects/disconnects the contacts and does not feed the phase to the output. There are loads of these, but they will all have one problem. You won't know from the HA whether the light is on or off. Because just because your relay will be disconnected doesn't mean someone hasn't switched the light on with a stair switch.
    So if you also want to monitor the on status of the lights, you will need to control the stair switches with a Zigbee/Wi-Fi relay, which will be the actuator for feeding ground to the SW input.
  • #5 21488182
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    It is exactly as shown in the diagram, and how do I control the relay with the stair switch?
    Will you send some schematic and device?
  • #6 21488379
    kindlar
    Level 42  
    Posts: 7820
    Help: 912
    Rate: 1603
    Like the light bulb, there are plenty of diagrams on the web.
  • ADVERTISEMENT
  • #7 21488457
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    Well, only then my stair switches won't work, unless I'm thinking wrong....
    Where would I mount such a relay?
    On the 1 wire from the switch to the controller?

    If I mount it in front of the switch, then if I have the relay off, I won't be able to switch on the switches, and vice versa.
  • ADVERTISEMENT
  • #9 21488686
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    What buttons?
  • #10 21488693
    hindoos
    Level 36  
    Posts: 3637
    Help: 286
    Rate: 652
    As far as I can see from the description, it should be possible to operate the relay in several modes, either bistable and then switch on impulse (bell switch) or monostable and then a traditional staircase circuit should work. It's just a shame that it requires 230v. I think Shelly used to make relays for 24vdc
  • #11 21488835
    kmarkot
    Level 31  
    Posts: 1364
    Help: 126
    Rate: 354
    hindoos wrote:
    then a traditional staircase arrangement should work.
    .
    Yes you are right a staircase will work.

    Added after 51 [minutes]:


    Wiring diagram for an OXT relay with stair switches. .

    In my opinion it should look like this . Of course connect N and L under the module
  • #12 21489052
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    kmarkot wrote:
    hindoos wrote:
    then a traditional staircase circuit should work.

    Yes, you're right - a staircase arrangement will work.

    Added after 51 [minutes]:


    Wiring diagram for an OXT relay with stair switches.

    In my opinion it should look like this. Of course connect N and L under the module



    So should I connect 230 V to this ?

    And if I switch on on the staircase, I can switch off on the relay and vice versa ?
  • #13 21489060
    hindoos
    Level 36  
    Posts: 3637
    Help: 286
    Rate: 652
    Yes, but you will find details in the manufacturer's manual for this module. I personally haven't dealt with them and haven't integrated them into HA either.
    This particular module is not in the compatibility database but it is similar and is supported by ZHA so it should work "out of the box" ;) https://zigbee.blakadder.com/OXT_SWTZ22.html
  • #14 21491943
    sajmon_mówi
    Level 5  
    Posts: 28
    Rate: 1
    kmarkot solution works, thanks ! 😁

Topic summary

✨ The discussion addresses connecting a Wi-Fi or Zigbee relay to a 24 V stair lighting controller to enable control via Home Assistant. The controller operates by switching the SW input to ground to toggle lighting. A voltage-free relay (dry contact) that closes the circuit without applying voltage is recommended to interface with the controller. However, such a relay alone cannot provide feedback on the light status if manual stair switches are used. To monitor and control lighting status reliably, a Zigbee or Wi-Fi relay module acting as an actuator to switch the ground feed to the SW input is necessary. The relay should support push-button (momentary) operation compatible with staircase switch wiring. A specific Zigbee dry contact relay module (OXT SWTZ22) requiring 230 V supply was suggested, which can be integrated with Home Assistant via ZHA. The relay can be wired in parallel with the stair switches, allowing toggling from either the physical switches or Home Assistant. Shelly brand was mentioned as a possible alternative with 24 V DC relays. The solution involves connecting the relay module’s N and L terminals to mains and wiring its dry contact output in series with the stair switch line to the controller. This setup enables bidirectional control and status monitoring of the stair lighting from Home Assistant and physical switches.
Generated by the language model.

FAQ

TL;DR: For a 24 V stair-light controller, use a Zigbee/Wi‑Fi dry-contact module to short SW to GND; "a 'voltage free relay' will suffice." Home Assistant can toggle it, but HA can’t infer state from manual switches without feedback. [Elektroda, hindoos, post #21487506]

Why it matters: It lets DIYers integrate 24 V stair-light controllers into Home Assistant without losing manual control.

Quick Facts

What’s the simplest way to control a 24 V stair-light controller from Home Assistant?

Use a Zigbee or Wi‑Fi module with a dry (voltage‑free) relay contact. Wire its contact across the controller’s SW and GND terminals. Do not feed any voltage into SW. This mirrors what a wall switch does on the 24 V side. Pair the module with Home Assistant and create an automation. [Elektroda, hindoos, post #21487506]

Where should I wire the smart relay so wall switches still work?

Place the relay contact in parallel at the controller, across SW and GND. Do not insert it in series with the staircase switches. Parallel wiring lets either the relay or any switch short SW to GND. Both manual and Home Assistant control then work independently. The module still needs 230 V L and N, wired separately. [Elektroda, kmarkot, post #21488835]

Can I keep traditional staircase switches, or do I need push buttons?

You can do either, depending on the module mode. Use bistable mode with momentary bell push buttons for impulses. Use monostable or staircase mode to work with existing two‑way wiring. Configure the relay’s input behavior in its app or during pairing. This preserves manual control while enabling HA automations. [Elektroda, hindoos, post #21488693]

Which Zigbee relay was suggested in the thread?

The OXT intelligent mini relay with dry (voltage‑free) contacts, Zigbee, and Tuya support was suggested. It provides a contact output that does not inject voltage, ideal for SW‑to‑GND control. Use it as an actuator to feed ground to the controller input. Confirm its mode in the manual before wiring. [Elektroda, kmarkot, post #21488647]

Does that OXT relay need 230 V power?

Yes. Power the module with 230 V AC by connecting Neutral and Live to N and L. The contact side remains isolated and dry for the 24 V control loop. Keep mains and low‑voltage wiring separate in the enclosure. Follow the module’s wiring diagram for terminal identification and safety. [Elektroda, kmarkot, post #21488835]

Is an OXT dry-contact relay compatible with Home Assistant ZHA?

A similar OXT SWTZ22 dry‑contact relay is listed as ZHA‑compatible. Pair it through Home Assistant’s ZHA “Add Device.” Then expose the relay entity for automations and dashboards. This provides local, low‑latency control on your Zigbee network. Always verify your exact model in the database before purchase. [“OXT_SWTZ22 — Zigbee Device Compatibility Repository”]

Will Home Assistant show the correct state if someone presses a wall switch?

Not without feedback from the circuit. The relay contact only actuates; it does not sense manual toggles. “You won’t know from the HA whether the light is on or off.” For true state, control the switch loop through the smart relay or add sensing. Otherwise, HA state can desynchronize after manual use. [Elektroda, hindoos, post #21487506]

Can I power the smart relay from 24 V instead of 230 V?

Not for the OXT shown. It requires 230 V AC for its electronics. Consider Wi‑Fi devices like certain Shelly models that accept 24 V DC. Confirm input voltage on the datasheet before wiring. Using the wrong supply can damage the module or be unsafe. [Elektroda, hindoos, post #21488693]

How do I wire it? (3-step quick start)

  1. Feed the Zigbee relay with 230 V AC (connect L and N) in a safe enclosure.
  2. Wire the relay’s dry contact across the controller’s SW and GND terminals.
  3. Set the module to staircase or bistable mode, pair to HA, and test both controls. [Elektroda, kmarkot, post #21488835]

Will putting the relay before the switches block manual control?

Yes, if you wire it in series before the switches, it can interrupt manual operation. Instead, place the relay contact in parallel at the controller, across SW and GND. Either path can complete the control circuit without blocking the other. This maintains manual control even when the relay is off. [Elektroda, kmarkot, post #21488835]

Did this solution work for the original poster?

Yes. The original poster confirmed success after implementing the suggested wiring. That validates adding a Zigbee dry‑contact relay to a 24 V controller. It achieved Home Assistant control alongside existing stair switches. [Elektroda, sajmon_mówi, post #21491943]

Are the relay contacts safe to use on the 24 V controller input?

Yes. Use the relay’s voltage‑free contact to bridge SW to GND on the 24 V input. The contact does not supply voltage; it only closes the circuit like a switch. This matches the controller’s expected signaling method. Ensure solid, low‑voltage terminations at the controller. [Elektroda, hindoos, post #21487506]
Generated by the language model.
ADVERTISEMENT