We believe math and science education should be free and accessible to everyone. Why education matters >

Distance Between Points Calculator

Calculate the straight-line distance between any two points in 2D or 3D space. This calculator also provides the Manhattan distance, the midpoint, and a step-by-step breakdown of the formula.

The Euclidean distance formula measures the straight-line distance between two points. It is a generalization of the Pythagorean theorem to any number of dimensions.

2D Distance Formula:

d = sqrt((x2 - x1)^2 + (y2 - y1)^2)

3D Distance Formula:

d = sqrt((x2 - x1)^2 + (y2 - y1)^2 + (z2 - z1)^2)

Manhattan Distance:

Also called taxicab or L1 distance, it sums the absolute differences along each axis: |x2-x1| + |y2-y1| (+ |z2-z1| in 3D). It measures the distance you would travel on a grid, like city blocks.

Midpoint Formula:

The midpoint is the average of the coordinates: ((x1+x2)/2, (y1+y2)/2) in 2D. It is the point exactly halfway between the two given points.

Applications:

Distance calculations are essential in GPS navigation, game development (collision detection), machine learning (k-nearest neighbors), physics (force calculations), and everyday tasks like finding the shortest route between locations.

Did this solve your problem?

Frequently Asked Questions

Search Calculators

Search across all calculator categories