hobbysoft.pro

Expertise

iOS geofencing and Core Location developer

I build location features for iPhone: geofences that trigger when someone arrives or leaves, background behavior that respects battery, and GPS measurement in the foreground. Two of my own apps use Core Location in production, Fokus Zone for location-based app blocking and My Disc Golf for GPS-measured throws.

By HobbySoft, iOS & Mac developer Updated

iOS geofencing development that works in the background

Geofencing on iPhone means defining an area, usually a center and a radius, and letting iOS tell your app when the device enters or leaves it, even if the app is not running. Core Location handles the monitoring at the system level, which is why it can work all day without draining the battery the way continuous GPS would.

Businesses use it for:

  • Arrival and departure triggers: check-ins, reminders, automations at a site.
  • Field and logistics apps that react when a driver reaches a depot or a customer.
  • Behavior that changes by place, like a quieter or more restricted mode at work or school.

Foreground location is a different job: live tracking, distance measurement and maps, where accuracy matters more than battery.

What is hard about location in production

The Always permission flow

Background region events need Always authorization, and iOS does not offer it on the first prompt. The usual path is When In Use first, then a request for Always at a moment where the benefit is obvious. The user can also pick Allow Once, which does not support background monitoring, or turn off Precise Location, which makes small zones unreliable. The app has to read its real authorization state, explain what is missing and keep working in a reduced form.

Twenty regions, not unlimited

Classic CLLocationManager region monitoring allows up to 20 regions per app, shared across all features. An app with more places has to pick the nearest ones and re-register as the user moves. Newer APIs such as CLMonitor change the programming model, but the same discipline applies: decide which conditions matter right now.

Timing and accuracy

Region events are not instant. The system waits until it is confident the boundary was crossed, so entry can lag, and a radius that is too small may never fire reliably indoors. Product copy should promise “when you arrive”, not “the moment you step through the door”.

Background relaunch

If the app was terminated, a region event relaunches it in the background for a short time. The work done there must be quick and self-contained: read stored state, act, finish. Anything that waits for the UI or a slow network call is lost.

GPS measurement in the foreground

Measuring distance with the phone means reading horizontalAccuracy, discarding poor fixes and being honest that phone GPS is typically accurate to several meters. Waiting a moment for a better fix often beats taking the first reading.

How I use Core Location in my own apps

Fokus Zone blocks apps by place. Users create focus zones at work, the library or the gym with a radius around any place, and restrictions switch on when they enter. Location is used only for geofencing, data stays on device, and location-based restrictions require Always permission, so the onboarding has to explain why. The hard part is connecting a region event to the Screen Time restrictions reliably while the app is in the background; that side is covered on my Screen Time API page. For the user view, see how to block apps by location.

My Disc Golf measures throws with GPS in its PRO tier: drop a pin, throw, walk to the disc and get the distance, with distance-training sessions and per-disc history. That is foreground accuracy work, the opposite trade-off from geofencing. More in measuring disc golf throw distance.

Location features I can build for your app

  • Geofenced triggers for arrivals, departures and dwell at your sites, with an honest permission flow.
  • Location-aware modes that change app behavior at work, school, a venue or home.
  • Distance, tracking and map features with MapKit, tuned for accuracy or battery as the feature needs.
  • An audit of an existing location feature that fires late, drains battery or gets rejected for unclear permission strings.

Apple’s Core Location documentation covers the basics; I handle the production edge cases around it.

Discuss your location feature

Describe the places and the trigger you have in mind and email contact@hobbysoft.pro. I will reply with what iOS can do reliably and what it cannot.

FAQ

Questions and answers

How many geofences can an iOS app monitor?

With CLLocationManager region monitoring, an app can monitor up to 20 regions at a time. Apps with more places swap the active regions based on where the user is.

Does geofencing need Always location permission?

For events while the app is in the background or not running, yes. iOS never offers Always on the first prompt, so the app has to earn it with a clear reason and a good moment to ask.

How accurate is geofencing on iPhone?

Good enough for buildings and campuses, not for a single room. The system confirms a boundary crossing before notifying the app, so events can arrive with some delay and very small radii are unreliable.

Does geofencing drain the battery?

Region monitoring is designed to be low power because the system handles it, unlike continuous GPS tracking. Battery problems usually come from apps that keep standard location updates running when they do not need to.

Have an app in mind? Let’s ship it.

I take on a small number of projects at a time and stay with them to the finish: one accountable developer, an EU company with clear invoicing, and support long after launch.

Hire me