What is the real distance between two cities? Not the straight line on a flat map — the great-circle arc across the curved Earth, which the haversine formula nails.
Great-Circle Distance (Haversine)Live
shortest path on a sphere
Controls
Presets
The shortest route between two points on Earth is a great-circle arc, not a straight line on a flat map. The haversine formula computes that distance from latitude and longitude, staying accurate even for nearly antipodal points. It powers flight planning, GPS, and every "distance between" feature — and explains why polar routes look curved on a Mercator map.
Reading this result: A great circle changes heading as you travel, so the 51-degree initial bearing is not the heading you keep — that constant-heading path (a rhumb line) would be longer.
Runs locally in your browser — free forever. Scale to the cloud when reality gets heavy.
★ Sign in to save this setupSave your tuned setup, or drop this simulation into your own site, docs, or course page.
How it works
The shortest path between two points on a sphere is a great-circle arc. The haversine formula computes its length from the two points' latitude and longitude, remaining numerically stable even for nearly antipodal points. It underlies flight planning, GPS, ride-hailing distances, and any "how far apart" calculation on Earth.
✦
Ask the AI about this model
The math, the assumptions, real-world uses, or a code translation — explained for this exact simulation.
Is this haversine great-circle distance tool really free?▾
Yes. Great-Circle Distance (Haversine) runs entirely in your browser using your device's own compute, so local use is free forever. You only pay Compute Tokens if you scale a job to the cloud.
Do I need to install anything?▾
No. Everything runs client-side in a modern browser — no downloads, no license, no account required to start.
Can I save or share my simulation?▾
Create a free account to save projects, and use a shareable embed or minted DOI to publish a live, interactive version anywhere.
How accurate are the results?▾
The solver uses established numerical methods, but results are for research and educational purposes and should be validated against experiment or professional review before you rely on them.