How are the distances for on and off site calculated?

  • Updated

Firstly, let us define a few terms: 

Customer Co-Ordinates: The GPS co-ordinates linked to a customer (either saved during the first visit, or manually added / edited by a user).

Visit Co-Ordinates: The first reliable GPS co-ordinates received after a visit has started.

On - Site: The customer's GPS co-ordinates are within an acceptable distance of the Visit Co-ordinates

Off - Site: The customer's GPS co-ordinates are not within an acceptable distance of the Visit Co-ordinates

The distance between these two points is calculated using the  Haversine formula , a very well known formula in navigation. We then apply an "error margin" to this distance (based on the accuracy of the co-ordinates, as well as the actual distance in order to allow for some correction).

For the "tech nerds" out there, here are the formulas we use:

Distance between points in meters:


 Customer locations (Latitude and Longitude)


Visit location (Latitude and Longitude)


Was this article helpful?

0 out of 0 found this helpful



Please sign in to leave a comment.