Ultimate Calculator
Geometry

Distance between Two Points Calculator

Find the straight-line distance and midpoint between two points on a coordinate plane.

Distance

5

Midpoint
(2.5, 4)
Horizontal and vertical change
3 and 4
  1. Change in x: 4 − 1 = 3
  2. Change in y: 6 − 2 = 4
  3. d = √(9 + 16) = √25 = 5

The formula

d = √((x₂ − x₁)² + (y₂ − y₁)²)

The distance formula is the Pythagorean theorem applied to coordinates. The horizontal and vertical gaps between the points form the two legs of a right triangle, and the distance is its hypotenuse.

How to use this calculator

  1. Enter x₁.
  2. Enter y₁.
  3. Enter x₂.
  4. Enter y₂.
  5. Read the answer on the right. It updates as you type, and the numbered steps underneath show how it was worked out.

Worked example

Using x₁: 1; y₁: 2; x₂: 4; y₂: 6.

  1. Change in x: 4 − 1 = 3
  2. Change in y: 6 − 2 = 4
  3. d = √(9 + 16) = √25 = 5

Distance: 5

Common questions

How do I find the midpoint of two points?

Average the x-coordinates and average the y-coordinates: ((x₁ + x₂) ÷ 2, (y₁ + y₂) ÷ 2).

Does the order of the points matter?

No. The differences are squared, so swapping the points gives the same distance.