InputTestHub

Distance Between Coordinates

Great-circle distance, initial and final bearing and the true midpoint between two latitude and longitude pairs.

Converters Nothing uploaded No sign-up Free, unlimited
Converters tool
Enter your figures and press Calculate.
In short The great-circle distance is the shortest path between two points over the surface of the earth, and it is what the haversine formula computes. Two results that come with it surprise people. First, the initial and final bearings are different: a great circle is not a straight line on a flat map, so its compass heading changes continuously along the route. London to New York leaves on a bearing of 288° and arrives on one of 231° — a swing of 57° with no turn made — which is why long-haul flight paths look curved on a Mercator map. They are not detours; they are the straight line, and the projection is what is bending. Holding a single compass heading the whole way instead is a rhumb line, which is simpler to steer and measurably longer. Second, the midpoint is NOT the average of the two latitudes and longitudes. Averaging is wrong by tens of kilometres over long distances and fails outright across the antimeridian, where averaging 170° and −170° gives 0° — a point on the opposite side of the planet from the correct answer of 180°. The model here is a sphere of radius 6,371.0 km. On the WGS84 ellipsoid the answer differs by up to about 0.5%, which matters for surveying and not for anything else. And this is surface distance rather than travel distance: no road, flight corridor or terrain is involved, so it is a lower bound on any real journey.

How to use the Distance Between Coordinates

  1. Enter the two coordinates in any notation.
  2. Read the distance in kilometres, miles and nautical miles.
  3. Check the initial and final bearings, which differ over long distances.

About the Distance Between Coordinates

Great-circle distance, initial and final bearing and the true midpoint between two points.

What people use it for

  • Finding how far apart two places are in a straight line.
  • Working out which way to point from one coordinate to another.
  • Finding a genuine halfway point rather than an averaged one.

Details

Methodhaversine on a sphere of radius 6,371.0 km
Nautical mile1,852 m exactly; statute mile 1,609.344 m exactly
Bearingsinitial and final differ — a great circle is not a constant heading
Midpointalong the great circle, not the average of the coordinates
Ellipsoid differenceup to about 0.5% against WGS84
PrivacyEverything runs in your browser. No coordinate you enter is sent anywhere
Distances are given in kilometres, statute miles, nautical miles and metres, all from the same computation.

Where this tool stops

Everything is computed from the WGS84 ellipsoid in your browser — no map service, no lookup and no network. Coordinates on an older datum such as ED50, NAD27 or a national grid will not agree with these figures, sometimes by hundreds of metres. Great-circle distances use a spherical earth of radius 6,371.0 km and differ from ellipsoidal distances by up to about 0.5%, which matters for surveying and not for anything else.

Frequently asked questions

Why do the initial and final bearings differ?
Because a great circle crosses each meridian at a different angle. The shortest path over a sphere is not a constant compass heading, so the direction you set off in is not the direction you arrive on. Over short distances the difference is negligible; over an ocean it is tens of degrees.
Why not just average the two coordinates for the midpoint?
Because that is not the halfway point on the sphere. Over long distances averaging is wrong by tens of kilometres, and across the antimeridian it fails completely — averaging 170° and −170° gives 0°, which is halfway round the world from the correct 180°.
Is this the driving distance?
No. It is the surface distance in a straight line, so it is a lower bound on any real journey. Roads, flight corridors and terrain all make the actual distance longer.
How accurate is haversine?
It is exact on a sphere and the earth is not quite one. Against a full ellipsoidal calculation the difference is up to about 0.5%, which is metres over a city and a few kilometres across an ocean. For surveying use an ellipsoidal method; for everything else this is fine.
Why does a flight path look curved on a map?
Because the map is flat and the path is not. On a Mercator projection the shortest route over the pole appears as a curve, but it is the straight line — the projection is what is bending, not the aircraft.
Is there a limit on how often I can use the Distance Between Coordinates?
It is free, with no account, no trial and no daily cap. Every converters tool on inputtesthub.com works the same way: open the page and use it.
Is what I paste into the Distance Between Coordinates stored?
No. The Distance Between Coordinates runs entirely in your browser using JavaScript. Because the work happens locally, the page also keeps working if your connection drops, and closing the tab is all it takes to discard everything.
What is the Distance Between Coordinates used for?
The most common reasons people reach for it: finding how far apart two places are in a straight line. Working out which way to point from one coordinate to another. Finding a genuine halfway point rather than an averaged one. It is built for exactly those cases rather than being a general-purpose tool with this bolted on.
What are the limits of the Distance Between Coordinates?
Everything is computed from the WGS84 ellipsoid in your browser — no map service, no lookup and no network. Coordinates on an older datum such as ED50, NAD27 or a national grid will not agree with these figures, sometimes by hundreds of metres. Great-circle distances use a spherical earth of radius 6,371.0 km and differ from ellipsoidal distances by up to about 0.5%, which matters for surveying and not for anything else. Knowing where a tool stops being trustworthy matters more than the cases where it works.
What are the reference figures here?
Method is haversine on a sphere of radius 6,371.0 km. Nautical mile is 1,852 m exactly; statute mile 1,609.344 m exactly. Bearings is initial and final differ — a great circle is not a constant heading. These are printed on the page itself, so you do not have to take them on trust.
Is the number rounded?
The calculation runs in double precision and the result is shown to ten significant figures, so converting a value and converting it back returns the original. What is displayed is rounded for readability; what is copied is not.

Related converters tools

All 1079
01

Number Base Converter

Converts numbers between binary, octal, decimal, hexadecimal and any base from 2 to 36, in…

02

Roman Numeral Converter

Converts numbers to Roman numerals and Roman numerals back to numbers, from 1 to 3,999,999.

03

Shoe Size Converter

Converts shoe sizes between US, UK, EU, Japan and centimetres for men, women and children.

04

Ring Size Converter

Converts ring sizes between US, UK, EU and Japan systems and shows the matching inside…

07

Bra Size Converter

Converts bra sizes between UK, US, EU, France, Italy, Australia and Japan, or works the size…

09

Hat Size Converter

Converts head circumference to US, UK and EU hat sizes using the real formula: the size is the…

10

Glove Size Converter

Converts hand circumference to glove size and letter size for men and women. The glove size is…