Slope Calculator

Find the slope between two points, the line equation y = mx + b, intercepts, angle, grade, midpoint and distance – with a graph.

Calculator

Was this tool useful?

About this tool

About Slope Calculator

Enter two points to get the slope (rise over run) and everything about the line through them, drawn on a small graph.

How it works

m = (y₂ − y₁) ÷ (x₂ − x₁). b = y₁ − m × x₁. Angle = atan(m). Grade = m × 100%.

Example

Points (1, 2) and (4, 8): m = 6 ÷ 3 = 2, so y = 2x + 0, at an angle of 63.43°.

How to use this tool

  1. Enter the coordinates of the first point (x₁, y₁).
  2. Enter the second point (x₂, y₂).
  3. Read the slope, equation and other properties.

Frequently asked questions

What does an undefined slope mean?

The line is vertical (x₁ = x₂), so the run is zero.

What is grade?

Grade is slope as a percentage, used for roads and ramps: a slope of 0.08 is an 8% grade.

Do I need to sign up?

No. The calculator is free, works in your browser and nothing you type is stored.

Can I use the Slope Calculator for homework?

Yes. The Slope Calculator shows the answer and, where possible, the method, so you can check your own working. Teachers usually want to see the steps, so use it to learn the method rather than only copying the answer.