3D Distance Calculator
What is the straight-line distance between two points in three dimensions? Enter the values below to calculate the result.
Result for the values shown.
Calculations run in your browser.
What to enter
| Input | Meaning and units |
|---|---|
| First x coordinate (length) | Enter first x coordinate in length; use the same basis as the other measurements. |
| First y coordinate (length) | Enter first y coordinate in length; use the same basis as the other measurements. |
| Second x coordinate (length) | Enter second x coordinate in length; use the same basis as the other measurements. |
| Second y coordinate (length) | Enter second y coordinate in length; use the same basis as the other measurements. |
| First z coordinate (length) | Enter first z coordinate in length; use the same basis as the other measurements. |
| Second z coordinate (length) | Enter second z coordinate in length; use the same basis as the other measurements. |
Understanding your result
Read distance (length) in the units and model stated on this page. The formula distance=hypot(x2-x1,y2-y1,z2-z1) defines the relationship; measurement accuracy and model applicability are separate from numerical precision.
Common mistakes
- Mixing input units or changing the physical meaning of a variable without changing the model.
Check your calculation
- Use the worked example as a known reference case, then change one input at a time and check the direction and units of the response.
Calculation checks, sources and review limits
What is the straight-line distance between two points in three dimensions?
What is the straight-line distance between two points in three dimensions? Enter the values below to calculate the result.
Common uses
- What is the straight-line distance between two points in three dimensions
How it works
distance=hypot(x2-x1,y2-y1,z2-z1)
Worked example
Enter First x coordinate: 0 length; First y coordinate: 0 length; First z coordinate: 0 length; Second x coordinate: 3 length; Second y coordinate: 4 length; Second z coordinate: 12 length. Results: distance: 13 length.