UTILS.
100% in-browser
📍

3D Distance Calculator

Calculate the straight-line distance and midpoint between two points in 3D space, with the x, y and z deltas.

About this tool

Enter the coordinates of two points in three-dimensional space to find the straight-line (Euclidean) distance between them, the midpoint and the change along each axis. It all runs locally in your browser.

The distance uses the 3D Pythagorean formula: distance = √((x₂ − x₁)² + (y₂ − y₁)² + (z₂ − z₁)²). The midpoint is simply the average of each coordinate: ((x₁ + x₂)/2, (y₁ + y₂)/2, (z₁ + z₂)/2). The component deltas Δx, Δy and Δz are the signed differences along each axis.

It is handy for 3D modeling, game development, physics, CAD and geometry homework. Set both z values to 0 to fall back to an ordinary 2D distance calculation.

Frequently asked questions

Which distance formula is used?
The Euclidean distance in 3D: the square root of the sum of the squared differences in x, y and z, a direct extension of the Pythagorean theorem.
Can I use it for 2D points?
Yes. Leave both z coordinates at 0 and the result is the usual 2D distance between (x₁, y₁) and (x₂, y₂).
What is the midpoint?
The point exactly halfway along the segment, found by averaging the two x values, the two y values and the two z values separately.
Are negative coordinates allowed?
Yes. Any real numbers work, including negatives and decimals, because the differences are squared before the square root.

More tools