Homekit presence status?

I'm having trouble with my wife's apple home presence. Trying to figure out if it's the cloud endpoint that i set up in Rule Machine, or if it's an apple home issue. But I can't for the life of me figure out where I can see apple home presence status.... Nowhere in the Apple Home app do I see the status of whether Apple Home considers my wife present or not present. What am I missing?!?!

1 Like

I have to assume you've setup a "Virtual Presence plus switch" device in Hubitat and shared that to Apple Homekit. You've then created Apple Automations to "copy" Apple's presence into the Switch portion of that device. You don't say any of that but because of "RM" I've got to assume you made it that far.

If Not, let's start there. Create two virtual devices, one for you, one for the wife. Both use the built-in "Virtual Presence with Switch" device type. In the Hubitat Homekit Integration, select the two devices.

For your wife, you must start by Inviting her device to also manage the Home.

On your Apple device, tap Automations in the Home App. Tap the + and Add Automation. Tap "People Arrive" Tap the "i" next to "Anyone Arrives" and pick just yourself. Tap Next. Now select the Virtual Presence device you created for yourself and be certain the switch is showing ON. (It'll need to be OFF in the next automation you create.)

Do the whole thing over again for "People Depart". That should work for YOU.

Do the whole thing over again, twice, using your wife's ID.

So.. the "trick" is to Invite (and accept) everyone who's presence you are going to track. Apple requires that each person approve, for obvious privacy issues. You know you have it right when you go to create that first Automation, and you have a list of people to select from.

Remember that you're tracking a device. My family have iPads and iPhones, I have to be sure I pick their iPhone to track during the invite process.

1 Like

Well the way I have it set up is from before the combined switch/presence sensor. I have an HE virtual presence sensor set up for each of my wife and I, and I use Apple Shortcuts to send a webhook to Cloud Endpoints that are set up in Rule Machine to trigger arrival/departure. All that works just fine for me. And it at one point worked well for my wife. But it's stopped working for some reason for her. The issue I'm running into is that I can't figure out where in Apple Home the actual presence status for my wife is listed - is there any way to figure out whether Apple thinks my wife is home, other than relying on the HE virtual device status?

EDIT: well I guess the upside to setting it up like you've done is that there is a device in Apple Home that shows the presence status.... the way I have it now there isn't. Maybe worth trying your approach then....

Well, using the Switch with Presence yields the same result. Not working despite seemingly having set up the automations correctly (and them working for my own presence)... buggers.

Every Automation has a "Test This Automation"

In the Arrive/Depart Automation click it and verify the Hubitat device toggles. Both Presence and Switch should change simultaneously.

You have to go into the correct automation, opposite of the state it's in. Then go into the other. And then of course, you have to do it all over again for EACH person.

For whatever reason, it's working now with the Switch with Presence approach. Thanks @csteele!

From what I’m interpreting from OP, the original question was how can he see the actual status of the phone’s presence (not the status of the virtual switches). I, too, have set up our iPhone’s presence detection via Homekit and integrated it with Hubitat and run automations using virtual switches successfully.

But, I am also curious how can I set up a way to view the actual status of the HomeKit’s phone’s presence (vs viewing the virtual switches). Is that possible?

The whole idea of the virtual switches is to mimic the actual status. What circumstances are you envisioning where that might differ?

I have the virtual switches that mirrors the real presence sensors. My ask is bc if virtual switches or automations somehow no longer works, it helps with troubleshooting to see if the actual HomeKit phone presence is still being detected correctly (the true source of the trigger).

The only time I’ve ever seen these out of sync is if an iPhone leaves or returns while turned off. The fact that Apple Home automations don’t trigger when an iPhone is turned back on outside of the home radius is something Apple should consider addressing and outside of our control as Hubitat users.

I think that might be better answered on an Apple forum. The mobile device knows where it is OR due to interference, it doesn't. I know when I go into Target, 10-15 steps in and I can't make calls can't bring up the Target app to find the shelf. I never specifically checked my location but I do know it does not trip my automations. My phone didn't suddenly decide it arrived back home.

If the phone/tablet/watch isn't getting GPS and it slides in or out of a geofence, the device doesn't know where it is. The virtual switch also doesn't know. There's a distinction without a difference. Sure the phone might not know but whatever it does know gets set on the virtual switch. Which pushes the whole GPS/Geo location back to Apple and the Carriers.

Yeah but we’re talking about a known location (your home) where interference is reliably predictable. It’s not the same as traveling to unknown areas with dead spots.

And with that in mind, that is exactly why being able to “see” if your phone device or hub is properly detecting your geo location when you arrive/leave Home is more critical.

Case in point, when initially setting up my phone presence with Hubitat and Homekit integration, it was not working, and had to go through a process of elimination to only deduce that my phone’s location service on the Apple Home app was not properly working. Would have been much easier to start troubleshooting if we can see if the hub is properly detecting your phone’s Geo location directly vs indirectly deducing where the problem lies (with the phone, the hub, the app, the integration, the automations, etc).

But I will take your advice and look in the Apple Forum. Thanks for your time.

So got responses from Apple Support. There is no direct way to see the phone’s home/away status in Home app. Instead, I was redirected to use “Find My” app to see if the phone’s location is within your home. Or just setup some automation notification (which is not quite the same thing)..

1 Like

In the wake of Life360 baring use of their API forthcoming, I wanted to find a way to have my daughters iphone using geofencing and the new HE homekit integration work together to detect her home/away status.

I use Android and have tasker set to turn on a virtual (cloud) switch on Maker API in HE when the device is within the boundary set in autolocation and reverse for departed.

However, I cannot figure out how this same mechanism would be achieved using HE homekit to communicate with the iphone home app and set a boundry for geofencing in iphone in the first place.

I have read so many post, but no technical details. Just add a home app automation to turn on/off a virtual presence with switch when the phone arrives.... How does it arrive, something has to determine where 'home' is in the first place, ie, geofencing. And how if not via HE maker API, aka webhooks.

Can any iphone home app person please explain in detail. I'm sure I can muddle my way though the home app or shortcuts or whatever is to be utilized.

Thank you..

1 Like

Unfortunately apple does not let user set the perimeter of home presence. You're home when apple decides you're. For us it's usually a minute or so after we arrive home, which is a little too slow in my use case.

I'm in the same boat, does anyone have a detailed step-by-step guide to setting up iPhone presence using HomeKit with Hubitat?

Do you have a Homekit hub?

Step 1) you must have a HomeKit Hub. That is an Apple TV or Apple HomePod. Without this, Automations can't be created.

Step 2) In Hubitat, create a Virtual Device, choose the Virtual Presence with Switch type in the drop down and name it something useful.

Step 3) select the new device in Homekit Integration (it will be in the Switch list.)

Step 4) The remaining steps are all done on your Apple mobile device.
In Apple's Home App, at the bottom center is Automation. You will create TWO automations, one for when you arrive, one for when you leave. They just set the switch state accordingly, otherwise identical.

Step 4A) Create a new Automation by tapping the + in the upper right, Add Automation.
Tap People Arrive (or When I Arrive) Tap Next and select the Hubitat Switch you added. Make sure the state of the switch is On. That's it for this Automation. Create a nearly identical one for When I Leave (or People Leave) and select the same switch, but make sure it's selected to be Off.

That's it for connecting presence from Apple to Hubitat. Apple detects you entering the Geofence and runs the Arrive automation, which turns On the switch. Apple detects you leaving the Geofence and runs the Leave automation, which turns Off the switch. Because you selected "Virtual Presence with Switch" Hubitat will track, both as a switch and as a presence sensor, the state of Apple's presence.

Each Automation has a Test This Automation. Use them to verify in the Hubitat virtual device you created.

If you get successful results using Test this Automation, then you know that everything from your Apple Mobile device all the way to Hubitat's device is working. It all relies on Apple detecting the Geofence for your home.

I use the virtual device in a Hubitat Rule to Open my Garage Door between 7am and Sunset. Although it works reliably, there is variability in exactly when it triggers. By that I mean, when I drive up, sometimes Presence is detected 300 ft down my street, other times it detects when I get to the driveway, on rare occasions it detects presence after I've sat in the driveway, waiting for 10 seconds or so. I attribute that to where I am in Apple's queue to send a notification. If there are 300 other people entering or leaving their Geofence, I have to queue up behind them. Most of the time, I'm at the top of the queue, but not every time. :smiley:


Excellent summary!

I'd only add that (AFAIK) the geofence parameters are a mystery locked deep in Apple's vault -- we end-users have no way to define the geofence, so don't bother poking around for it.

ETA - meant that for OP, not csteele :wink:

That may be true today, but it wasn't always so. I've had no need to alter my Geofence in years, but once upon a time, the circle was adjustable. I remember years ago I set a geofence for my kid's school. I was just experimenting with the whole geofence idea and I "dropped a pin" on the school and was able to enlarge the circle. I have no idea if that feature still exists.

1 Like