Free · Math · m = (y₂ − y₁) ÷ (x₂ − x₁)

Slope Calculator

Enter two points to get the slope, the line’s equation in slope-intercept form, the y-intercept, the distance, the midpoint and the angle, with steps.

Find the Slope Between Two Points
Results update as you type.
—

—
—
—
Slope formula: m = (y₂ − y₁) ÷ (x₂ − x₁), or rise over run. The line is y = mx + b, where b = y₁ − m × x₁.

Slope = rise ÷ run = (y₂ − y₁) ÷ (x₂ − x₁). For the points (2, 3) and (6, 11), the slope is (11 − 3) ÷ (6 − 2) = 8 ÷ 4 = 2. The y-intercept is 3 − 2 × 2 = −1, so the line is y = 2x − 1.

Key takeaways
  • Positive slope rises, negative slope falls, zero slope is flat.
  • A vertical line has an undefined slope.
  • Once you know m, find b with b = y₁ − m × x₁.

How to Use the Slope Calculator

  1. Enter the first point (x₁, y₁) and the second point (x₂, y₂).
  2. Read the slope (as a fraction when the coordinates are whole numbers), the equation, and the distance, midpoint and angle.
  3. Use the steps to check your homework.

Slope Formulas

m = (y₂ − y₁) ÷ (x₂ − x₁)
y = mx + b   |   b = y₁ − m·x₁
SlopeWhat the line doesExample
PositiveRises left to rightm = 2
NegativeFalls left to rightm = −1/2
ZeroHorizontaly = 4
UndefinedVerticalx = 3

Worked Examples

Example 1: (2, 3) and (6, 11)

  1. m = (11 − 3) ÷ (6 − 2) = 8 ÷ 4 = 2
  2. b = 3 − 2 × 2 = −1
  3. Line: y = 2x − 1

Example 2: (−1, 4) and (3, 2)

  1. m = (2 − 4) ÷ (3 − (−1)) = −2 ÷ 4 = −1/2
  2. b = 4 − (−1/2)(−1) = 3.5
  3. Line: y = −0.5x + 3.5

Slope in Real Life

Slope is a rate of change. If your test scores rise from 70 to 85 over 3 tests, the slope is 15 ÷ 3 = 5 points per test. A road that rises 6 m over 100 m has a 6% grade; the percentage calculator handles that conversion. In physics, the slope of a distance–time graph is the speed; try the speed distance time calculator.

Tips

  • Keep the order the same: if you start with y₂ on top, start with x₂ on the bottom.
  • Watch the signs when subtracting negative coordinates.
  • Distance between the points uses the Pythagorean theorem.

Frequently Asked Questions

What is the slope formula?

Slope m = (y₂ − y₁) ÷ (x₂ − x₁): the change in y divided by the change in x between two points.

How do you find the equation of a line from two points?

Find the slope m, then the y-intercept b = y₁ − m × x₁, and write y = mx + b. For (2, 3) and (6, 11), m = 2 and b = −1, so y = 2x − 1.

What does a slope of 0 mean?

The line is horizontal: y does not change as x changes.

Why is the slope of a vertical line undefined?

Both points have the same x, so the run is 0, and you cannot divide by zero.

What is rise over run?

Rise is the vertical change (Δy) and run is the horizontal change (Δx). Slope = rise ÷ run.

How do you turn a slope into an angle?

Use the inverse tangent: angle = tan⁻¹(m). A slope of 1 is a 45° angle.

More Calculators You Can Use

Free tools that pair well with this one.

Pythagorean Theorem Calculator

Hypotenuse and missing sides with steps.

Open calculator

Speed Distance Time Calculator

Find speed, distance or time with units.

Open calculator

Percentage Calculator

Turn any fraction into a percent.

Open calculator

Mean, Median & Mode Calculator

Averages, range and standard deviation.

Open calculator

Z-Score Calculator

Z-scores, percentiles and the normal curve.

Open calculator

Percent Error Calculator

Compare a measured value with the true value.

Open calculator
Scroll to Top