Any way to get HomeKit devices statuses into Hubitat?

I thought I was on to something last night with a iOS Shortcuts automation that took the Velux skylight open position as a number and used IFTTT webhooks to set a virtual shade device in Hubitat.

The IFTTT rule was working well, but then I discovered that Shortcuts can trigger URL events (the IFTTT webhooks) but Automation activities (like open at 9am, close at midnight) doesn’t seem to be able to have GET URL as an output.

The only thing I could think of that would work, and REALLY don’t want to do it is to have a device automation that checks the status of the skylight then fires off the webhook and have it run every hour or half hour, just means I have to create 24-48 automations (times 5 skylights) and I only get 30 min granularity, and it’ll mean that I’ll have a shortcut notification to clear on my phone every 30 mins, which is unacceptable.

I will be following this to see if anyone comes up with a good solution. I have been looking for a way to do this for other HomeKit only devices and have not been able to find any method. The closest I came was to set up Homebridge which is a good method for getting things from the rest of the IOT world into Homekit. Then I created a virtual switch. Then I set up a rule in HomeKit that changed that virtual switch whenever the HomeKit only presence sensor changed status. From there I was able to go Homebridge to Node Red to Hubitat. There are so many pieces involved that it was more an academic exercise than something I would want to rely on (though it has been suprisingly robust so far).

That said for a simple 2 state item it worked well. I abandoned this approach for temperature and humidity sensors because similar to what you are describing the number of rules would become too unweildy.

Good Luck as if you get an answer it will probably help me too.

Honestly I'd be mostly ok with open/closed status for the Velux skylights and their blinds (actual position would be ideal, but...) I just didn't want a solution that is held together with duct tape, which the Shortcuts+Automation+IFTTT+Webhooks+virtual shade feels like it is. Also if I want to change something or I mess up I'd have to update as many as 240 rules....

Maybe MQTT? There is a beta app in HE...

Don't know the solutions for HomeKit but assume there are some.. barring that I would say maybe Node-RED as a good controller for both HE and HK?

A lot of the paths I've gone down rely on some additional server running something (or raspberry pi) I find Hubitat already fragile enough (rules randomly not running, conflicting apps, etc) that I'm very wary of laying another possibility of failure on top.

I simply just use homekit automations to turn on a virtual switch on Hubitat and vice versa.

Works very well. Been running this way for a year now.


Can you explain this further? when you say "home automation" you mean in the iOS home/shortcuts app? how do you have it control the virtual switch, that's what this thread is about... setting a status from a homekit device to a virtual (or real) device in Hubitat...

Yep I agree - that's why I use Node-RED to greatly reduce HE's resource usage - no rules apps etc. I've found it to be an exceptional way to tie disparate systems together among other advantages but thats just my use-case.

Create the virtual switches and expose them through maker/homebridge.

Setup homekit automations to do the following.

Virtual switch turns on - Turn on HomeKit Switch
virtual switch turns off - turn off homekit switch
Homekit switch turns on - turn on virtual switch
Homekit switch turns off - turn off virtual switch


ok so the virtual switches are in homebridge? didn't know that was an option, and homebridge and hubitat will talk (via Maker API) to sync the switch states?

Do you need the virtual switch on the homebridge side or can you link a real device (the Velux Skylight and shades) to a virtual device in Hubitat?

For some reason I thought only one directional communication could happen Hubitat -> Hombridge, not the other way around.

I guess I'll order a Hoobs now then...

Let’s backup. Just to be clear. You want to get homekit device states passed over to Hubitat, correct.

The virtual switches are created under Hubitat and exposed over maker and homebridge. The automations are created under the Home app as described above.

Maybe consider building a small vm and setting it up for free so you can test?

1 Like

Yes, thats correct, I have some Velux Skylights and Blinds that are HomeKit enabled. I'd like to show their state (and control them?) via Hubitat

I am not sure how that will work if you want to control blind positions. You may need several virtual switches depending on what you want.

If I were you, I’d spin up a VM with Ubuntu and install homebridge and test.

Here is an example of my garage door.

HomeBridge will present a HE virtual switch to the HomeKit ecosystem as a regular switch. Whatever automations you can do with switches on the HomeKit/Apple side can flip the virtual switch on HE...although an Apple TV may be required.

I made a virtual switch in HE for a HomeKit-only door lock:

From HE, I can lock/unlock the door by flipping the virtual switch.

On HomeKit, I made two automations to lock/unlock the door when the HE virtual switch flips on/off.

On HomeKit, I also made two automations that flip the HE virtual switch if the door is locked/unlocked by key, knob, or code.

Since I'm generally happy with the HomeKit arrive/depart detection, I made two more HE virtual switches (that turn right off) triggered by HomeKit automations "whenever anyone arrives home" and "when the last person leaves" for triggering automations in HE.

I was running HomeBridge with Wink for a few years now, and just spun up a Docker instance of HOOBS on a shared Raspberry Pi this weekend. I highly recommend HOOBS over messing with editing JSON files on HomeBridge for ease of setup.....

Its fine if there is 2 shades/dimmers per device, thats not an issues that's how it is in HomeKit/Home app now.

Is it easy to define what the mapping is? for instance the Skylights and shades in HomeKit show as windows and shades (support open/close and set position in 0-100) Closest thing in Hubitat would be a shade or dimmer.

I use homebridge config ui x.

1 Like

I bought a Starling hub a few weeks back to get Nest Cams / Thermostat / Protects working in the iOS Home app. That's working well. Do Nest cams show in Hubitat with this homebridge setup?

What door lock? Does it use Bluetooth or wifi? Does it require cloud?

Schlage HomeKit-only lock, Bluetooth, relays through nearby Apple TV AFAIK. I'm not recommending it to anyone, but is has worked acceptably for us flipping a HomeBridge dummy switch (like a HE virtual switch) for HomeKit automations.

I just migrated it to a HE virtual switch yesterday, so I don't have any live feedback on how this kludge works with HE yet.....

I hope this is the right place to ask. If not please point me to the proper thread.
I would like to have access to my Nest thermostat on my HE. I use a Google account so this limits my choices. If I understand correctly, HomeKit has access. I believe Homebridge can connect to HE.

I would rather not add do something like this:
HE <-> Homebridge <-> HomeKit <-> Nest

When I looked at homebridge, I see they have a plugin for Nest Does this mean I don't need HomeKit to accomplish what I'm after?