Mobiles, Shakespeare, Politics, Usability, Security.

The absolute horror of WiFi light switches

I've just got a WiFi light switch.

As I've explained previously, swapping out all my existing light bulbs with Smart Bulbs would be hugely expensive and has the disadvantage of not working when the switches are off at the wall.

A WiFi light switch (theoretically) allows me to control the lights from my phone - and anyone else to use the physical buttons on the wall. That helps avoid this scenario:

WiFi built into the switch means I don't need to use a hub to control my devices - I can connect directly to them and not have to worry about hardware incompatibilities.

The UK has a unique way of wiring houses which doesn't lend itself well to automated control. The switches which work in the USA and EU, simply won't work in a UK set up. This makes switches rare and expensive.

I've gone for the Lanbon WiFi Light Switch - £50 on Amazon - or around £35 direct from China. For more technical information (although not much) take a look at the L5-HSGT1's product page.

What's In The Box

The switch itself is pretty good looking:
Lanbon Wifi Light Switch Front-

The back is slightly weird - this is obviously a fairly generic design which can be re-purposed for multiway switches.
Lanbon Wifi Light Switch Back-

As for the rest of the kit...
Lanbon Wifi Light Switch Screws-

Yup! A pair of mounting screws - that's it! No fitting instructions, no glossy leaflet, nothing! Oh well, how hard can this thing be to install...

Wiring In

Working with electricity is dangerous. Remember to switch off the power to your lights at your consumer unit. If in doubt, get a qualified electrician to help. I followed this guide to replacing UK light switches.

Wiring the switch is trivial - as long as you can remember which wire is which. There's just one small problem...
Lanbon Wifi Light Switch Depth-
The depth of the pattress box is insufficient to contain the switch! Obviously microchips aren't quite a tiny as necessary yet.

OK, I can try drilling that deeper later - let's power up this baby and see if it works!

Lanbon Wifi Light Switch Wall-

Blinken lights! Touching the light icon provides a satisfying "clunk" somewhere inside the switch, but didn't change the state of the lights. Perhaps it needs to be set up first?

The App

Remember when I said that the package didn't come with any instructions? That wasn't quite true - there are some QR codes on the side:
Lanbon Wifi Light Switch QR Codes-

A quick scan and...
Lanbon Wifi APK-

Hmmm... Do I really want to download an app from China over HTTP? Guess I don't have a choice!

Interestingly, the Lanbon website offers a more recent version of the app to download. This obviously isn't an organisation set up with high-quality "it just works" in mind.

I prepared to install the app - when I was hit by this:

Those are some ridiculously scary permissions! I can understand wanting microphone access (voice control) and maybe GPS (turn lights on when I get home) - but why does this want to send SMS or place calls? Why does it need my contacts and the ability to take photos?

A quick virus scan showed nothing overtly malicious - but I decided to offer up a sacrificial tablet to run the app on. No way am I risking my main device with this software!

The software is of the usual sub-standard quality I've come to expect from cheap electronics. No set-up wizard, just dumped into a complicated screen.
Lanbon Wifi Light Switch App-

Pressing the "User Manual" button gave this monstrosity:
Lanbon Instructions-

I held down the light switch button until the WiFi indicator started flashing. I then connected my tablet to the WiFi (a separate network - I didn't want to risk sticking this on the same network as everything else yet). I clicked the "Auto Search" button and, somehow, the tablet found the switch and set it the network's details. Result!

Lanbon Send Config-

The app presents this rather lazily designed screen. Only the blue icon on the left works as a switch.
Lanbon Button-

Let There Be Light!

And, dear reader, can you guess what happened when I clicked it?

Yup - the square-root of bugger-all!

Under The Covers

Before trying it on another socket, I thought I'd crack it open to see what's going on inside.
Lanbon Wifi Light Switch Under The Cover-
As I suspected, it's a generic unit which can be used for 1-, 2-, or 3-gang switches. No LEDs are soldered on to the spare ports.
Interesting to note a different part number printed on the inside - L5 HSCL LB v16.

Remaining Neutral!

I made a telephone call to Prad - the Amazon seller who supplied me with the switch - he was incredibly helpful but sadly confirmed that the switch requires a neutral wire. Something which had unfortunately been left out of his listing.

It turns out that this lack of neutral wiring is a common problem.

The WiFi Plug Glass has this fairly prominent warning:
Neutral Wiring Warning-fs8

And Vesternet have an excellent page explaining the challenges of fitting smart switches to UK homes.

Short of rewiring parts of my house, it looks like the switch will be useless to me. So back it goes.

Decompiling the Software

Part of the problem with the software is that it is designed to work with a suite of products. It contains references to security cameras, home alarm systems, infrared controllers, fans, curtain controllers, and half-a-dozen other things.

There's no widget support - which is crucial for a lighting app. No one wants to find an app, wait for it to open, find the right light etc. I just want to put a simple toggle on my homescreen - in exactly the same way Lifx does.

As far as I can tell, there's nothing malicious in the software - it's just poorly constructed.

Of course, with Android Lollipop's new permission model, I can deny the app access to anything that I'm uncomfortable with. During my brief use of the app it didn't ask for anything other than WiFi access.


As I didn't get the switches working, I didn't dive too deeply into the API. I did spot this curious activity though.

When the light switch wasn't connected to the WiFi, the app assumes that it is on a different network to the switch and tries to communicate over a cloud service.

Lanbon Hong Kong Server-

That IP is hard-coded into the app.

whois An unknown server in Hong Kong! The venerable nmap reckons the server is running Microsoft Windows Vista Home Premium SP1, Windows 7, or Windows Server 2008. Ok...

Right, it's communicating on port 80 - but let's see what incredibly secure authentication it is performing...

Lanbon UDP Packet-

Hmmm... Some of those numbers look familiar...
Lanbon Wifi Light Switch ID-

Ah. So it sends a packet with the light switch's ID number in it. That appears to be all. I assume that the switch makes a similar persistent connection to that IP address so it can listen out for instructions. I was too scared to port scan the light switch.

I'm guessing, with a small amount of effort, you could toggle strangers' lights to your heart's content.


It looks like I'm going to have to go for the hub and spoke model of smart switches. That is, a light switch which trickles enough electricity to power an RF receiver while keeping the lights off - controlled by a WiFi connected hub.

Hopefully one which is more secure than this!



A picture of mark mark

I used to be a electrician in a forma life but now a software engineer but you will find that the earth is common with the neutral so for your electronics to work you can connect the earth to the neutral you should find that this will work. So just take a wire from your earth connection to the neutral in the unit (

A picture of Moe Moe

Nope, where should there be any current leaking? The housing is made of plastic. The RCD just triggers, when not all current that flows out on mains is returned on neutral. That happens only if something has a direct earth-connection. Don't see that.

A picture of Simon Simon

Terrance, totally dumb question. I used jadx to decompile the apk. But couldnt figure out the server information details.

Please can you help me to see where the server information is located.

Will be ever grateful

A picture of tobinharris tobinharris

Nice write up. Is there anything you didn't like about Hub and Spoke?

If it's the power consumption, I think the enOcean kit generates it's own power, or something :)

We make the apps for the Energenie MiHome range, so I get to play with their kit in the office quite a lot! It's a relatively young product but is made for the UK market and works well. Find them on Vesternet and Amazon. There's a Rasberry Pi module for tinkerers too. It's a Wi-Fi hub and spoke setup. There is a light switch too, which I haven't tried yet but someone in the office probably has.

A picture of Terence Eden Terence Eden

It is mostly the worry about getting stuck with incompatible kit. Look at what happened with the Hue light debacle a few months ago.

A picture of trailmaxailmax trailmaxailmax

May I ask the reasons why you would like to wifi-your-switches? any practical reason?

I really want to do something similar with my home, but I can't find a good enough reason to actually tinker with this stuff. Motion sensors light bulbs in cupboards and the Hive thermostat are the useful automation things I could come up with. Everything else - I struggle for reasons.

A picture of Terence Eden Terence Eden

Remote controlling switches is very useful for people with mobility issues. It also allows them to be used when away from home. As well as being able to set automated schedules.

A picture of costumediy costumediy

"Draw over other apps" -permission allows it pretty much steal anything on your UI, including things you type on the keyboard (read: passwords). On top of that an anonymous server in Hong Kong... uh oh...

A picture of tobinharris tobinharris

That's a fair point. At home I installed Z-Wave stuff 4 years ago, with Micasa Vera. It's fairly future proof but the problem is the hub software is like something written in the 90's. And SmartThings and Apple HomeKit could in theory be a fairly good interop point with nice app user experience, if more manufacturers supported it.

A picture of Veyrdite Veyrdite

If the RCD is correctly wired then current going from active to earth will trip it. The earth-nuetral link *should* (don't assume) be on the opposite side of the RCD to your house wiring.

Disclaimer: I don't live in the UK nor am I an electrician, but it would be stupid to wire the earth-nuetral link on the same side of the RCD as your house wiring. It would not be able to trip if you were touching something earthed and something active simultaneously.

I do not recommend using your earth wire as a return path for current.

A picture of Rob Rob

Veyrdite is correct, mark has clearly lost his mind.
Wiring a circuit with potential to earth is dangerous and against Part P of the Building Regulations here in the UK.

A picture of edwin edwin

Informative article. I think I will stick to RF operated switches. Can Switch these from my phone and from all over the world as well with a small hub that has bluetooth and internet connection.

A picture of edwin edwin

Totally agree with Veyrdite on the neutral/earth issue. And yes the RCD will trip as there is current going from live to earth instead of live to neutral

A picture of JohnC JohnC

Thank goodness Mark is not still an electrician. Returning power on the earth wire is a potential death trap. If that earth wire ever becomes broken along its path to the neutral the rest will be drawn up to mains voltage and anything else "earthed" on it is now live.

A picture of William William

If you've not already sent it back, any way of measuring how many watts that switch is drawing when idle? One of my issues with wi-fi light switches is all the extra, unnecessary, power consumption. Perhaps some of the better ones have a low power state, but…

For users with mobility issues, wouldn't it be simpler to have a second switch installed elsewhere in the room so they could toggle from one or the other (e.g. like bedside switches in hotels?)

I wonder if there's a risk of obsolescence too; does these switches use a recent wifi protocol?; can you apply software updates to the switch?; in the event of a power cut, how long until the switch "boots up" / does it remember it's previous state? There's no LED, correct? So how do you know for sure if the bulb has blown? Never mind what if the Internet and/or the Hong Kong Windows server is down / DDOsed etc….

So, um, not for me. (You know can still get those timers you plug in if you want the lights to come on/off when you're not at home?)

A picture of Terence Eden Terence Eden

Some good questions - I've sent the switch back, but I'll answer what I can.

Didn't read what the idle power draw was. But they didn't get warm and they only have to run a relay, LED, and 2.4GHz module.

The mobility thing is interesting. People - even those with restrictions - tend to move around. Having two switches isn't as convenient as a switch you carry with you. It's also quite expensive to run switches everywhere.

Boot-up seemed fairly instant. If you've ever tried LIFX bulbs they remember state and connect to WiFi within seconds. There was an LED on the switch, and the sound of the relay clicking would probably alert you if there was a dead bulb. The switches still work as physical buttons even if your WiFi network goes down - so no worries on that front.

As you correctly identify - having a DDoS take out the server managing your switches would be unfortunate!

I'd get a timer, but like most people I work irregular hours.

A picture of William William

Thanks (sorry – had I looked at your photos properly I could have answered some of my own questions.) Hopefully in a few years things will be better – right now I feel as though whatever option I might choose for lighting/heating etc. will probably need to be replaced.

A picture of Alex Gibson Alex Gibson

Sheesh. Matches my own experiences trying to find a reasonably priced wifi switch. I have decided to roll my own based on ESP2866s and Raspberry Pi server.

A picture of Gaurav Gaurav

Hi Terence

Great write up! I have been doing some mock testing with Wifi Light Switches here in Mumbai. In India, all homes have a neutral wire and I haven't faced any problems in using these switches. The new iOS app by Lanbon is not very great but still an improvement over the last one.
Lanbon seems to be the only company making direct Wifi controlled switches. Rest all are dependant on an additional host / hub / controller. I wanted to know if you can provide some insight to obtain the Source Code / API from their app as I was working on a project to make a common app for lights & security (I have managed to integrate a camera, wifi door bell & sensors from different makes so far into my app).
Any help shall be appreciated. Thanks in advance.

A picture of Terence Eden Terence Eden

Hi Gaurav,
Firstly - do be careful with these switches. They create a permanent connection from your network to a Chinese IP address. You need to isolate the network - if hackers crack Lanbon then they have a direct connection into your network.
If Lanbon go bankrupt or stop supporting these switches, you may not be able to control them.
I suggest asking Lanbon for the API details. If they won't provide them, you can try decompiling the APK and see if that helps.
Best of luck.

A picture of Neil Neil

Hi Terrence, great write up.

I'm currently developing a two wire wifi enabled smart switch that can connect to your wifi router or to a home automation gateway using the Enocean 868mhz protocol which I'm hoping to launch on Kickstarter towards the end of summer.

The switch can dim CFL & LED retrofit bulbs and I'm designing it specifically for the uk market.

Any thoughts to help my product development?

A picture of Terence Eden Terence Eden

Sounds really interesting. Made sure it's suitable for shallow patresses - that is, don't make people drill extra holes. Happy to beta test it :-)


What do you reckon?

%d bloggers like this: