In short
With geofencing, a participant’s phone sends a prompt when it crosses a virtual boundary around a place. In three studies with the Samply app, prompts arrived most reliably with a radius of at least 100 m, at places where people stayed for several minutes, and on iOS rather than Android devices. Prompts on leaving a place arrived later or were missed more often than prompts on arriving.
What geofencing does
A geofence is a virtual boundary around a location, defined by a centre point and a radius. The phone detects when it enters or leaves the area, and each of these events can trigger an action. In experience-sampling research the action is a notification with a link to a short survey, an intervention or an experimental task, delivered while the participant is at the place or has just left it.
Geofencing differs from continuous location tracking, which records the participant’s position at regular intervals. Tracking produces sensitive data, drains the battery and often leaves gaps. With geofencing, the phone only reports that a boundary was crossed. When participants choose the locations themselves, for example their home or workplace, no location data need to be transferred to the researcher.
How the method was tested
Shevchenko and Reips (2024) evaluated geofencing as implemented in Samply in three studies. Two measures describe how well it worked. Sensitivity is the share of actual arrivals or departures that produced a notification. Precision is the share of notifications that matched an actual arrival or departure.
- In Study 1, four evaluators walked prepared routes in a city centre, a residential area and a forest. Each route had 15 locations with a radius of 10, 50 or 100 m. Across 360 tests, the study varied the operating system, radius, environment, Wi-Fi setting and type of event.
- In Study 2, two evaluators repeated the tests with an external GPS tracker as the reference (120 tests) and compared walking through a location with staying in its centre for 5 minutes.
- In Study 3, 58 students received notifications on their own phones when they entered or left the university in November and December 2022, and reported each day whether they had been at the university.
Results
In Study 1, 82.5% of the visits to a location produced a notification. Arrival notifications came on average 87 m from the centre of the area and departure notifications 234 m from it. iOS devices missed fewer notifications than Android devices, while Android sent its notifications closer to the boundary. Sensitivity was lower in the forest, where parts of the route had no mobile internet connection.
Study 2 confirmed the difference between the operating systems. A larger radius and staying for 5 minutes increased sensitivity, and departures were detected less often than arrivals. iOS sent arrival notifications before the phone crossed the boundary, Android after it.
With the students’ own phones in Study 3, sensitivity and precision were both 70% for arrivals. For departures, precision was 89% and sensitivity 18%, so most departures produced no notification. When an arrival notification was sent, participants were at the university 97% of the time. The false alarms therefore came mostly from delayed or repeated notifications, not from a wrong location.
Recommendations for study design
The paper summarises its results as recommendations for researchers:
- Use a radius of at least 100 m. With a 10 m radius, Android phones missed notifications and iPhones sent them too early.
- Choose places where participants stay for at least 5 minutes.
- Record the operating system and device model, and give participants instructions for the battery settings that stop background tasks on some Android phones.
- Avoid areas without mobile internet or with network congestion, and place the boundary in an open area.
- Ask participants to keep Wi-Fi switched on. With Wi-Fi off, departure notifications were delayed.
- Expect more variable timing for departure prompts than for arrival prompts.
- Avoid overlapping areas, use fewer than 20 locations per device, and add control questions such as “Are you at the location now?” in the prompt and “Have you been at the location today?” at the end of the day.
Location is still processed on the participant’s phone, so the consent form should explain what the app detects and what is sent to the researcher.