I have a rather complicated situation with the LEDs I'm trying to install.

There will be a railing on top of the posts and I’m want to attach the LEDs to the bottom of the railing. Here’s were it gets a little complicated. I’m hoping to do motion sensors on both the top and bottom of the stairs. Plus, the only outlet available for this is the one next to the post in the picture so the power source has to be there.

I have done some small LED projects in the past, but nothing quite like this. I’ve tried to do some research but nothing I’ve found so far will work for my situation.

Thanks in advance for any help or advice. I am just trying to figure out if this is possible and if it’s not what your would recommend.

enter image description here

enter image description here

  • 1
    It is not clear what you are asking about - motion sensors, how to attach the leds to the banister etc Mar 21, 2023 at 23:12
  • Are these LEDs just for ordinary lighting of the stairway? Or is this an art project or something else unusual? Any reason ordinary switch boxes can't be wired up to permanent light fixtures? Mar 21, 2023 at 23:12
  • @RohitGupta I apologize for the lack of clarity. i’m asking about the motion sensors and whether this is possible.
    – Jamie
    Mar 21, 2023 at 23:45
  • @manassehkatz-Moving2Codidact it’s not for an art project or anything. What do you mean by switch boxes? sorry i’m very new to this.
    – Jamie
    Mar 21, 2023 at 23:46
  • It might get a little klugey, but what about a 360 degree motion sensor at the top of the stairs (capturing all activity on the stairs) that then activates the led string? amazon.com/Sensky-Ceiling-Occupancy-Sensitive-110V-240VAC/dp/… (I was also looking for 3-way motion sensors and found nothing, and was looking for DC 360 degree sensors and found nothing.) Mar 22, 2023 at 0:37

2 Answers 2


Generically, this is a 3-way switch light circuit with two motion sensors. Let's start with the 3-way switch light circuit. Based on comments, OP is totally new to electrical wiring. So I will start with a paraphrase of Harper's usual advice:

  • Read, read, read. Get some books (you can borrow from the library in most places - no need to buy if you don't want to) and read up on how to do residential electric wiring. Watching videos and reading things online can help a lot too. The problem is that a lot of online information is of questionable quality. A published book generally sticks to code and proper practices.
  • Practice, practice, practice. For example, when it comes to using wire nuts, practice on some pieces of wire and wire nuts before doing the real work on the permanent wires in your house.

And some terminology:

  • Cable - In most places you can use non-metallic cable, a.k.a, "NM cable" or the trade name "Romex". In some places you must use individual wires inside conduit - if that is the case then there are some more steps involved. This type of cable is referred to as /2 if it has two insulated wires (black and white) plus bare ground. /3 has three insulated wires (black, red and white) plus bare ground.
  • Box - also "switch box", "junction box", "receptacle box" - these are all the same, except for size. Often the same box can serve all sorts of functions depending on what is placed on the front of it. Boxes are available in both plastic and metal forms. I prefer metal for a whole bunch of reasons.
  • Cables must be inside walls or if they are outside walls they must be protected from damage (e.g., covered with wood or Legrand Wiremold or placed in conduit).

The typical setup for a 3-way switched fixture (there are many variants that are actually equally OK) is:

  • /2 from power (e.g., from an existing receptacle box) to switch box 1
  • /3 from switch box 1 to switch box 2
  • /2 from switch box 2 to light fixture

In some cases, the light fixture is a hard-wired device. In other cases it may actually be a receptacle with a power pack (transformer) plugged into it.

In a traditional 3-way circuit, the 3 wires vary in function but in the above configuration neutral + 2 travelers. Depending on the position of switch 1, one or the other traveler is hot at any time and the other wire is not hot. Then depending on the position of switch 2, either the hot or not hot wire is connected to the light fixture.

Now we get to the complications. Motion sensors are common add-ons to simple switches. But they need power to work. In a standard 3-way configuration, the 2nd 3-way switch does not have power available for its internal functions! That is a big problem if you need motion sensors in two places.

Smart switches to the rescue!

A smart switch is essentially a tiny computer hiding inside a switch. Depending on the type, it can include WiFi access, other remote forms of wireless control and/or monitoring, timer, dimming and many other things. One of the great things about smart switches is that they can use a number of different methods to communicate with each other instead of using two travelers. As a result, many (not all) smart switches can communicate using one wire for hot (always hot), one wire for neutral and one wire for signaling.

Now to see if we can find a smart switch to do what you want...

One possibility is Lutron Caseta. They have a motion sensor which can be added to a system of Caseta switches. Which means you should be able to use a Caseta switches at the top and bottom of the stairs and "link" them to the motion sensors.

I highly recommend having actual physical switches at the top and bottom of the stairs, even with motion sensors. There are times when motion sensors don't react as quickly as you would like, or turn off the light because you are sitting on the stairs for a few minutes, etc.

  • 1
    Note that since these seem to be plug-in lights (of any sort, doesn't matter that they're LED), the 3-way switches need to control the outlet that the lights are plugged into, not the lights directly (as most would think). In the study, where you see a 3-way setup controlling a light fixture, just mentally substitute the outlet instead. Also, read up on splitting an outlet for "always hot" and "switched hot" control. +1
    – FreeMan
    Mar 22, 2023 at 12:04

The easiest solution these days may be home automation hardware -- a smart switch on the light, a pair of motion detectors that can talk to whatever you're using to run the rule, and a rule that says when motion is detected turn on the light for N minutes.

There are multiple options for the details if this, but that starts getting into an essay about the advantages and disadvantages if a local hub and local radio protocols vs. wifi and running the rule on someone else's server. My house has some of both, on both decisions.

Beyond ease of installation, this approach allows more options for the future and more complicated logic. For example, I want a light turned on for a few minutes when I come in through the front door but not when I leave; that's handled by two sensors and a combined rule that runs only if the door opens without being preceded by motion in the front hall.

CAVEAT: If the switch box does not contain a neutral wire -- if you're looking at an old-code switch loop -- few smart switches will be compatible with it. There are solutions, but they may raise the complexity back into the same range as doing this all in hardware.

CAVEAT: If the light is already on a two-way switch circuit (as is often true for stairwell lights), this approach would need either need a smart two-way or two smart switches and more attention to how they get hooked up in the boxes, depending on exactly which products you get. Again, increased complexity of installation.

I believe there are already Answers addressing those caveats.

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.