Flight distance calculator
Find the great-circle distance between two airports or two points, in kilometres, nautical miles and statute miles, with the bearing, the midpoint and an approximate flight time.
Runs entirely in your browser
Latitude is positive north and negative south, longitude is positive east and negative west.
Distance
A straight-line great-circle estimate on a spherical Earth (mean radius 6,371 km), accurate to about 0.5%. Not for flight planning or navigation: real routes are longer because of airways, winds and procedures. Airport data: OurAirports, public domain, about 4,500 large and medium airports with an IATA code.
How to find the distance between two airports
- Type an airport code (IATA like JFK or ICAO like EGLL) or part of its name in each box, and pick it from the list. Or switch to coordinates and enter latitude and longitude in decimal degrees.
- Set your cruise speed and its unit to see an approximate flight time.
- Read the distance in km, nautical miles and miles, the initial and final bearing, and the midpoint of the route.
How the distance is calculated
The distance uses the haversine formula (R. W. Sinnott, "Virtues of the Haversine", Sky and Telescope, 1984). With latitudes φ1, φ2 and longitudes λ1, λ2: a = sin²(Δφ/2) + cos φ1 · cos φ2 · sin²(Δλ/2), then d = 2R · atan2(√a, √(1−a)), where R is the mean Earth radius of 6,371.0088 km (IUGG). Kilometres are converted to nautical miles by dividing by 1.852 and to statute miles by dividing by 1.609344, both exact.
The initial bearing is θ = atan2(sin Δλ · cos φ2, cos φ1 · sin φ2 − sin φ1 · cos φ2 · cos Δλ), and the midpoint of the great circle follows the formulas in Chris Veness's Movable Type Scripts, which are standard spherical trigonometry. The final bearing is the reverse of the bearing back from the destination, turned half a circle.
Because the Earth is an oblate spheroid, ellipsoidal methods such as Vincenty's can differ by up to about 0.5%. For route length, wind and fuel, this page is only an estimate. Not for flight planning or navigation. Airport positions come from the public-domain OurAirports data set and are the reference points of the airports, not runway ends.
Questions
What is a great-circle distance?
It is the shortest path between two points on a sphere, along the arc of a circle that is centred on the middle of the Earth. Long flights follow routes close to it, which is why they look curved on a flat map.
How accurate is it?
The haversine formula on a sphere with a 6,371 km mean radius is within about 0.5% of the true distance on the Earth's slightly flattened shape: for JFK to London Heathrow it gives about 5,540 km. The coordinates are rounded to about 100 metres, which does not matter at this scale.
Why is my real flight longer?
Aircraft follow airways, avoid restricted areas and weather, and use departure and arrival procedures, so the flown distance is usually 5 to 10% more than the great-circle distance. The flight time here is simply distance divided by the speed you enter, with no taxi, climb, descent, wind or holding.
What is the initial bearing?
It is the compass direction, in degrees from true north, you would head in when leaving the first point along the great circle. It changes along the way, so the final bearing at the destination is different. The bearing is true, not magnetic.
Which airports are included?
Large and medium airports that have an IATA code, taken from the public-domain OurAirports data, about 4,500 of them. If yours is missing, use the coordinates mode. Codes and names are matched in your browser, and the list is downloaded from this site only when you open this page.
What is a nautical mile?
One nautical mile is exactly 1,852 metres, which is about one minute of latitude. Aviation uses it for distance and, as knots (nautical miles per hour), for speed.