I’m designing a desk with electrical parts onboard that need to be plugged into a wall outlet.

I’d like the desk to have two power inlets that can plug into the wall—one on each side of the desk—so the user can use whichever one is closest to their wall outlet and unsightly cable excess is minimised.

For obvious reasons the two inlets can’t be directly wired together, but I’m hoping this could be (safely and legally) achieved using a relay that switches between the two inlets—thus they are physically never connected to one another and you never have a ‘male to male’ situation. I’m also hoping the relay could automatically switch to whichever side it detects voltage from (since the user will generally only have one inlet plugged into the wall).

Is this at all a thing? One electrician I spoke to said it’s perfectly fine (it was his idea), another guy at my local electrical store said this is the worst idea he’s ever heard. The one thing I do know is I’ve never seen a device with two power cables.

Thanks in advance.

  • 1
    \$\begingroup\$ Sounds like a very complicated solution to a simple problem. Have the power wire come out of the desk in the middle and/or give nice routing options to make it so that only one wire is requied. To do what you are suggesting safely sounds very expensive, power hungry and unreliable. \$\endgroup\$
    – Puffafish
    Commented Aug 23, 2022 at 6:44
  • 1
    \$\begingroup\$ Thanks for the reply Puffafish. The cable-in-the-middle option doesn’t work for this design for reasons that are kinda hard to get into, but if this thing doesn’t work I’ll have the cable just come out of one side of the desk instead of both. I’m curious—does the power-hungry/unreliable part relate to it automatically sensing voltage? If I had to opt for a manual switch I think it’d still be worth pursuing. \$\endgroup\$ Commented Aug 23, 2022 at 6:50
  • \$\begingroup\$ Well many servers have multiple power inlets due to redundant power supplies, but they also don't switch between the inlets as they both run a separate power supply which gets combined at a later stage. It might be worth telling what your device is and why it would need two inlets, as it does sound very hazardous putting relays to switch between inlets as if something fails it may expose users to mains voltages. \$\endgroup\$
    – Justme
    Commented Aug 23, 2022 at 7:11
  • 1
    \$\begingroup\$ The desire for two inputs is really just cosmetic, so there isn’t a situation where the cable is on the left, but the power outlet is on the right, so the cable goes across the floor and looks bad. Basically I’m designing a product for OCD people… haha. But to answer your question the electrical components are a standing desk mechanism, wireless chargers, and a powerboard that could have anything plugged into it. I will ultimately put safety first, but I’m hoping there’s some kind of contactor where it’s physically nigh impossible for a failure to result in the two inputs coming into contact. \$\endgroup\$ Commented Aug 23, 2022 at 7:36

1 Answer 1


Yes, this is practical and simple to do.

You have two mains inlets: A and B.

Use a double-pole double-throw (DPDT) relay with a mains-powered coil that's connected to inlet A. That's a two-pole changeover relay.


simulate this circuit – Schematic created using CircuitLab

When there is power at just inlet A or on both A and B, the relay switches to inlet A as the power input.

Otherwise, it switches to inlet B as the power input, whether inlet B has power or not.

The only factor to consider is what the load is your relay will switch, which you describe as 'electrical parts'. Make sure the contact current rating is enough (plus a margin, say 20..50%) for your worst-case peak current.

If that load is high-current or inductive, you may want to consider snubbers across the contacts. Better still, you can use a more expensive contactor instead of a relay.

  • 1
    \$\begingroup\$ Amazing Tony, thanks for this advice. Part of the onboard electronics is a 10A powerboard, so the current being drawn really depends on what the user has plugged in and I’ll have to plan for the maximum, so I think I’ll go with the contactor option you mentioned. Any idea why a lot of people seem to think this is a bad idea? It seems like a pretty simple and I assume common piece of circuitry. \$\endgroup\$ Commented Aug 23, 2022 at 7:02
  • 1
    \$\begingroup\$ Another thing I forgot to ask—what happens with the ground cables for each inlet? Can they just be wired together with no relay/contactor? \$\endgroup\$ Commented Aug 23, 2022 at 7:06
  • 1
    \$\begingroup\$ Ground is ground. You don’t switch it. \$\endgroup\$
    – Kartman
    Commented Aug 23, 2022 at 7:10
  • \$\begingroup\$ The problem is the user interface. For example : if only one lead in plugged into an outlet and the other is in connected and if your system does not work as planned/expected (for whatever reason) the user will spend a lot of time trying to plug the other side in. And it still won't work. And the PAT guy will fail your product as they also have no clue what to test. The manual explaining your scheme will have been lost or not read. \$\endgroup\$
    – D Duck
    Commented Aug 23, 2022 at 7:56

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.