Homekit Compatible Sonoff Firmware Without A Bridge

Generally speaking, home automation isn’t as cheap or as easy as most people would like. There are too many incompatible protocols, and more often than not, getting everything talking requires you to begrudgingly sign up for some “cloud” service that you didn’t ask for. If you’re an Apple aficionado, there can be even more hoops to jump through; getting your unsupported smart home devices working with that Cupertino designed ecosystem often involves running your own HomeKit bridge.

To try and simplify things, [Michele Gruppioni] has developed a firmware for the ubiquitous Sonoff WIFI Smart Switch that allows it to speak native HomeKit. No more using a Raspberry Pi to act as a mediator between your fancy Apple hardware and that stack of $4 Sonoff’s from AliExpress, they can now talk to each other directly. In the video after the break you can see that the iPad identifies the switch as unofficial device, but since it’s compliant with the HomeKit API, that doesn’t prevent them from talking to each other.

Not only will this MIT licensed firmware get your Sonoff Basic, Sonoff Slampher, or Sonoff S26 talking with your Apple gadgets, but it also provides a web interface and REST API so it retains compatibility with whatever else you might be running in your home automation setup. So while the more pedestrian users of your system might be turning the porch light on with their iPhones, you can still fire it up with a Bash script as nature intended.

Of course, if you don’t mind adding a Raspberry Pi bridge to the growing collection of devices on your network, we’ve got plenty of other HomeKit-enabled projects for you to take a look at.

38 thoughts on “Homekit Compatible Sonoff Firmware Without A Bridge

  1. Why is a lamp that can be switched on/off from a phone app or web page called “smart”. It is not smart. It just has a remote control. A smart lamp is a lamp that turns on if people are home and it is dark in the room. At least in my head…

    I really do agree on that there are too many competing systems for smart devices. If I like to replace a normal dumb light switch in my home today I can buy any brand or style I want. Even the old switch was installed in the 80’s. I’m not interested in replacing ALL the equipment in my smart home system every five years or so when a device dies and that model is no longer produced. There needs to be a common standard protocol that can last for decades, and a standard form factor of the devices that fits standard house wiring systems.

    1. “Turn on the lamp when someone is home and the room is dark” is a trivial automation you can create and run with Homekit. Or bash, since with a 1:1 phone:person everyone has a MAC address. There are other types of sensors and software triggers you can use to add the smarts (but you do it yourself).

      Wholly agreed on a need for standardization. But you know what they say about standards… everyone’s got one.
      I personally prefer making the switches smart rather than the bulbs, which goes a good ways towards fitting in with existing hardware.

      1. That kind of automatic lamp is something I have longer than iPhones or Homekits exist in my toilet . A cheap pyroelectric sensor/switch for less than 10,- It does not even need software or an internet connection. No it is not and needs not to be remote controlled.

    2. I have found that the Shelly1 is a much-improved version of the Sonoff. It is smaller and fits in the electrical box. It works with 3-way switches. It will work from the web without any modifications. It is rated at 15 amps, the Sonoff is rated at 10 amps and most light circuits are fused to 15 amps, therefore, it could be a fire hazard, It is much easier to install. I replaced all my Somoffs with Sheey1s and they are much faster also.

        1. I haven’t tried one yet, but the Shelly 1’s are ESP8266 as well, and are reflashable:
          https://shelly.cloud/shelly1-open-source/
          https://github.com/arendst/Tasmota/wiki/Shelly-1

          Nice form-factor. One problem is price, the other is that up here anyway, just about all the outlet and switchboxes are grounded steel, so there may be problems with RF.

          Agreed with the general sentiment that a remote-controlled light does not a smart-home make… but it is the first step and most people’s first conception of what it entails. Currently, useful integrated home automation is mainly available to the rich (Crestron etc), or the hacker, with some toylike stuff that loops through Alexa or whatever being tried by the average non-tech.

          Lots of progress yet to be made to have “commodity” smart outlets and switches as the default.

    1. This is a great link, thanks for sharing. I have used the RavenSystem firmware on my SonOffSV’s to control my garage doors. Homekit picked them up, and I was able to install them with minimal configuration. The new version of iOS (13) and CarPlay display the garage door on my car’s screen when I am leaving home and when I arrive back at home. Excellent find!

  2. Unable to get it to connect to my WiFi. I have the sonoff basic and flashed two of them. Once I connect to the sonoff and select the WiFi network in the captive portal, it displays a blank page.

    1. Same here…. The way to solve that is burn any firmware (arduino ide examples) that connects to wifi. Connect to your wifi and then burn the above firmware again. The esp (at least for me) holds the info for the wifi. After I did these steps it connected to the network but I could not find it in the Home app on Ios. I have it working now with RavenCore

      1. Hi Guys
        As i´m a noob and know nothing about development .
        Someone knows if there is any tutorial for Ravencore + Apple homekit? I bought the new Sonoff touch T2 and T3 and my will is use with Homekit.

    1. Hey Nico, I’m strageling to make this work with Sonoff-Mini, as I’m trying to flash the firmware with DIY mode tool over WiFi but it is just NOT accepting the Bin files.. it says that firmware can not be greater than 508k, even if my Bin files are less than that.

      Could you please share the steps you’ve managed to make it work ??

      Thanks!

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.