Latitude Longitude Distance Calculator

Find the great-circle distance between two latitude and longitude points with the haversine formula.
Results in kilometers, miles, nautical miles, and bearing.

Distance

This tool measures the shortest distance between two points on the surface of the Earth, the kind of straight line a plane or a ship would actually follow. That path is called a great-circle route, and because the Earth is a sphere it is not the same as a straight line drawn on a flat map. The math behind it is the haversine formula, a 19th-century navigation method that stays accurate even for points very close together, where simpler approaches lose precision.

You enter two coordinates as decimal degrees. Latitude runs from -90 at the South Pole to +90 at the North Pole, and longitude runs from -180 to +180, negative for west of the Greenwich meridian. The calculator returns the distance in kilometers, miles, and nautical miles all at once, plus the initial bearing, which is the compass heading you would set off on to follow the great circle. (The bearing changes along a great-circle route, so it is the starting heading, not a constant one.)

A few honest limits. The formula treats the Earth as a perfect sphere with a mean radius of about 6,371 kilometers. The planet is actually a little flattened at the poles, so real distances can differ by up to roughly half a percent. That is fine for trip planning, aiming a long-range antenna, or estimating a flight, but not for survey-grade work, which uses the heavier Vincenty or geodesic methods. And this is distance over the ground in a straight line, not the driving distance by road, which is always longer because roads bend around terrain.


How we build and check this calculator

This calculator runs entirely in your browser, so the numbers you enter stay on your device. The math behind it is written by hand and tested against worked examples and standard references before the page goes live.

SuperGlobalCalculator is independently built and maintained. See how we build and verify our calculators.


Embed This Calculator

Copy the code below and paste it into your website or blog.
The calculator will work directly on your page.