I have a smart light bulb that needs constant power connected in order to be controlled via my smart home. However, I want my guests to be able to control the light via a switch as well.

I bought a small Sonoff switch that requires no neutral to work, since I do not have neutral in my switch wall boxes.

What I’m thinking is that I can let the light bypass the switch and connect the switch to the Sonoff smart switch, and then using automations, control the light whenever the physical or sonoff switch is triggered.

However, I wanted to verify if the circuit I’m thinking of wiring up is safe to use. The sonoff needs no neutral wire but requires power (Line) in both its Lin and Lout to allow a small amount of current to leak in order for it to power itself.

Will I create a sort circuit by bridging two Line cables together and is this dangerous? Will the sonoff switch work, or the current will just bypass it since there is a path with less resistance? And finally, is this connection safe to do?

The current connection

The proposed circuit for the sonoff switch to create a “detached relay”


2 Answers 2


Here's the part you're missing.

Sonoff Wiring Diagram

The Sonoff device must be wired in series with the load just like a regular switch. And just like any other switch, if you bridge the pole with the same line hot wire, nothing will happen because both sides of the switch will always be hot. There would be zero potential between in and out, so the device would be off.

What I’m thinking is that I can let the light bypass the switch

You have to ask yourself why the switch is involved in the first place. If you're going to bypass the switch then it doesn't need to be connected to anything.

If you want to use this Sonoff smart device to control whether the load is on or off then you need to connect the load to the "L Out" wire.

If you want the load to have continuous power, then this Sonoff device is the wrong product.

For a true "bypass" you could get their RFR2 model, hook it up literally anywhere that has hot and neutral, pair it to an RF remote, and voila, you've got a Sonoff device and remote switch that's not connected to any load.

  • Thank you for your detailed explanation! What I'm essentially trying to solve here is for the physical light switches on my wall to be able to control the smart lights, without cutting power to them. This can be done when there is a neutral wire, since the sonoff switches can work in a "detached relay" mode where they don't cut the power to the device. However, from your explanation, I understand that without a nutral wire (A.K.A. re-wiring my light switches to have neutral) I won't be able to achieve what I want.
    – Lucas P.
    Commented Dec 28, 2023 at 12:56
  • @LucasP. That's not what I said. You have the wrong device and the wrong wall switch. Adding a neutral wire won't solve the original problem. Commented Dec 28, 2023 at 14:20
  • The Sonoff Mini R4 supports a "Detached Relay" mode which continutes to power the load and just sends the physical switches' signal to the app (Home Assistant in my case), but it requires a neutral wire. I was wondering if the same can be achieved with the Sonoff ZB Mini L2, since my switches don't have a neutral wire behind them, but from your answers I understand that the no-neutral sonoff can't be powered in parallel with the load. The neutral (wifi) version of the switch I'm talking about is this one: sonoff.tech/product/diy-smart-switches/minir4
    – Lucas P.
    Commented Dec 30, 2023 at 19:24

That won’t work. You’ve just shorted out the switch. It’d work exactly the same as if the switch weren’t there at all. In fact, the switch won’t even get power to function.

There’s basically no way to both provide constant power to the light and also switch power to the light.

  • 1
    Thank you for your reply! I don't want to cut the power to the light. I want the light to have constant power, and the (physical) switch to be able to control the Sonoff switch (and then I'll trigger the smart light bulb on/off through my home automatons). However, I'm not sure if by connecting both Lin and Lout of the Sonoff together if the Sonoff will get power, or it won't, since there is no point for current to flow through the sonoff (and the physical switch), when it can flow directly to the bulb. Will this work?
    – Lucas P.
    Commented Dec 23, 2023 at 18:08
  • Essentially, I'm want to create a parallel Line to the Line that will power the bulb, in order to power the Sonoff, and I don't know if its either dangerous, or if it just won't power the device at all.
    – Lucas P.
    Commented Dec 23, 2023 at 18:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.