Free math tool

Slope Calculator From Two Points

Find the slope between two points, show the rise and run, and catch vertical lines cleanly when the slope is undefined.

Reset

Ready

Enter values to get the answer.

This page keeps the calculation direct: answer first, then steps, then explanation and examples.

Steps

  1. Pick one of the example inputs or enter your own values.
  2. Use Solve to generate the direct answer and the conversion steps.
  3. Copy the result or share the URL with the query string intact.

Why it works

Slope measures change in y compared with change in x. The formula m = (y2 - y1) / (x2 - x1) is just a compact way to compare that vertical change to the horizontal change.

Common mistakes

  • Subtracting x-values and y-values in different orders.
  • Flipping rise and run so you compute run/rise instead of rise/run.
  • Forgetting that a vertical line has undefined slope because the run is 0.

Worked examples

Slope between (1, 2) and (5, 10)

Rise is 8, run is 4, so slope is 8/4 = 2.

Slope between (2, 1) and (2, 9)

Run is 0, so the line is vertical and the slope is undefined.