Calculate the shortest distance between two points on Earth using latitude and longitude.
Last updated: April 2026 | By Patchworkr Team
A great circle is the largest circle that can be drawn on any sphere—a circle whose center coincides with the sphere's center. Any great circle divides the sphere into two equal hemispheres. On Earth, the equator is the largest great circle; meridians of longitude are also great circles passing through both poles. The critical principle: the shortest path between any two points on a sphere's surface lies along the great circle connecting them. This geodesic distance is always measured along the sphere's surface, not through space. The Haversine formula and spherical law of cosines mathematically compute this distance from latitude/longitude coordinates: d = 2R × arcsin(√(sin²((latr-lat₁)/2) + cos(lat₁) × cos(latr) × sin²((lonr-lon₁)/2))), where R is Earth's radius (~6,371 km). The formula accounts for Earth's spherical shape: ignoring curvature produces Pythagorean errors exceeding 1% on journeys >100 km. This becomes critical for aviation, maritime navigation, telecommunications, and geospatial analysis where small angular differences compound into vast surface distances.
Great circle navigation revolutionized transportation: flights from New York to Tokyo follow great circle routes, reducing travel distance by 2,500+ km compared to straight latitude-line routes. GPS systems use great circle calculations for accurate turn-by-turn directions. Satellite operators compute great circle distances to determine signal coverage zones, antenna orientation, and relay path optimization. Earth observation satellites schedule imaging based on great circle geometry to ensure ground station visibility. Telecommunications networks route signals via great circles for minimal latency. Oceanography models ocean currents using great circle arcs. In cosmology, great circle distance on the celestial sphere helps astronomers identify star patterns. The haversine approach avoids trigonometric singularities at poles (unlike other formulas) and maintains numerical accuracy for both very close and antipodal points. Understanding great circles connects spherical geometry to practical navigation, connecting abstract mathematics to billion-dollar infrastructure and life-critical applications in aviation and emergency response.
Input two geographic coordinates: (lat₁, lon₁) and (lat₂, lon₂)
Why: Great circle distance depends on both latitude and longitude of both locations. Latitude ranges -90° to +90°, longitude -180° to +180°. Precision matters: 1° latitude = ~111 km distance change.
Convert degrees to radians: multiply each coordinate by π/180
Why: Trigonometric functions (sin, cos, arcsin) operate in radians, not degrees. This conversion is essential for accurate Haversine or spherical law of cosines calculations.
Apply Haversine formula to compute the angular distance
Why: The Haversine formula is numerically stable for all distances, especially short routes. It avoids rounding errors that plague other spherical trigonometry formulas near antipodal points (opposite sides of Earth).
Multiply angular distance by Earth's radius (6,371 km or 3,959 miles)
Why: Angular distance is in radians—a unitless measure. Multiplying by radius converts to ground distance. Different radius values (accounting for Earth's oblate spheroid shape) yield different precision levels.
Convert result to desired unit (km, miles, meters, etc.)
Why: Different applications require different units. International aviation uses kilometers; US maritime uses nautical miles. Unit conversion ensures results match user expectations and system requirements.
Flight Distance: New York to London
A straight line through the Earth is impossible for surface travel. Great circles follow the surface.
Great circle follows Earth's curvature. Straight line is shorter but impossible on the surface.
Latitude: -90° (South Pole) to +90° (North Pole). Longitude: -180° to +180° from Prime Meridian.
Great circles are the shortest routes, saving fuel and time.
Almost. It's an oblate spheroid (slightly flattened). This calculator uses the sphere approximation.
A robust formula for calculating great circle distances, avoiding precision errors at small distances.
Yes, just change the radius value for the planet's size.
Half the circumference ≈ 20,000 km, between antipodal points (opposite sides).