Free distance calculator
Find the distance between two points on a coordinate plane — enter (x₁, y₁) and (x₂, y₂) and see the exact distance, updated live, as you type.
On this page10 sections
d = √((x₂−x₁)² + (y₂−y₁)²). Standard 2D Euclidean distance.
Results are estimates. Consult a professional.
How the distance calculator works
Distance in a coordinate plane is found using the Pythagorean theorem. The straight-line gap between two points is the hypotenuse of a right triangle whose legs are the horizontal and vertical separations.
The formula works in any consistent unit — metres, kilometres, miles, feet. The result is in the same unit as the coordinates. For travel distance, use d = speed × time and ensure the units match (km/h × hours = km).
Weisstein, Eric W. — Distance. MathWorld, Wolfram Research.Worked example: distance between two coordinate points
Find the straight-line distance between A = (2, 3) and B = (6, 7).
Distance formula results for integer coordinate pairs
Common coordinate pairs and their exact distances. The starting point is always the origin (0, 0) for simplicity.
| Point A | Point B | Distance (exact) | Distance (≈) |
|---|---|---|---|
| (0, 0) | (3, 4) | 5 | 5.000 |
| (0, 0) | (5, 12) | 13 | 13.000 |
| (1, 1) | (4, 5) | 5 | 5.000 |
| (2, 3) | (6, 7) | 4√2 | 5.657 |
| (0, 0) | (8, 6) | 10 | 10.000 |
| (1, 2) | (7, 10) | 10 | 10.000 |
| (3, 3) | (6, 7) | 5 | 5.000 |
| (0, 0) | (1, 1) | √2 | 1.414 |
Distances computed using d = √((x₂−x₁)² + (y₂−y₁)²). Integer results are Pythagorean triples.
Tips for distance calculations
Whether you are working with coordinates, maps, or travel times, these tips help you get an accurate result.
- Use consistent units — mixing metres for x and kilometres for y gives a meaningless result; convert all coordinates to the same unit before calculating.
- The order of subtraction does not matter — (x₂−x₁)² equals (x₁−x₂)² because both are squared; distance is always positive.
- Pythagorean triples give exact integer answers — pairs like (3,4,5), (5,12,13), and (8,15,17) are worth memorising for quick mental checks.
- For map distances, use the Haversine formula — the Euclidean formula assumes a flat plane; for geographic coordinates (lat/lon) over long distances, Earth's curvature requires the Haversine or Vincenty formula.
- Speed × time for travel distance — if you know rate and time, d = r × t is simpler than coordinates; ensure units match (km/h × h, or mph × h).
Accuracy and limitations
This calculator uses the Euclidean distance formula, which gives exact straight-line (as-the-crow-flies) distance on a flat plane. It is not suitable for geographic distances over large areas where Earth's curvature matters. For driving or walking routes, actual travel distance is always longer than the straight-line result. Calculations use double-precision floating-point arithmetic (≈15 significant digits of accuracy).
Key terms
About this calculator
Part of our math calculators suite — explore all calculators.