Math Solver Free

Slope Calculator

Slope from two points or a line equation — instantly and free.

How to Find the Slope of a Line

Slope is the number that captures how steep a line is and which way it leans: how many units y changes for each unit x changes. A slope of 2 means “up 2, right 1”; a slope of −1/2 means “down 1, right 2”. This calculator finds that number two ways — from any two points on the line, or straight from the line’s equation. Enter the coordinates x₁, y₁, x₂ and y₂, or switch to the equation tab and type something like y = 3x − 2, and it returns the slope m along with the rise, the run and the subtractions in between.

From Two Points

Subtract the y-values (rise), subtract the x-values (run), then divide. Keep the point order consistent — (y₂ − y₁)/(x₂ − x₁) gives the same answer whichever point you call “first”.

Reading the Formula, Symbol by Symbol

The formula is m = (y₂ − y₁) ÷ (x₂ − x₁). The letter m is the slope itself. The pair (x₁, y₁) names one point on the line: x₁ is its horizontal position, y₁ its height. The pair (x₂, y₂) names a second point the same way. The top of the fraction, y₂ − y₁, is the rise — how far the line climbs between the points. The bottom, x₂ − x₁, is the run — how far it travels sideways. Slope is rise measured against run.

From an Equation

In y = mx + b the slope is staring at you: it is m. Parallel lines share the same slope; perpendicular lines have slopes that multiply to −1 (negative reciprocals).

How to Use This Calculator

  1. Pick a mode with the tabs at the top of the tool: “From two points” or “From equation”.
  2. Points mode: fill the four boxes — x₁ and y₁ for the first point, x₂ and y₂ for the second. The starting values, (1, 2) and (5, 10), produce a slope of 2.
  3. Equation mode: type the line into the Line equation box, either as y = 3x − 2 or in standard form, like 2x + 3y = 6.
  4. Press Find Slope. The panel below states the slope, walks through the rise and run substitutions, and tells you whether the line rises, falls, sits flat, or stands vertical.

Worked Example 1: Slope Through (2, 3) and (6, 11)

Plotting these two points shows a line climbing steadily to the right, so we expect a positive slope of moderate steepness before we calculate anything.

  1. Label the points: (x₁, y₁) = (2, 3) and (x₂, y₂) = (6, 11). Labelling first prevents the classic mix-up of subtracting in different orders.
  2. Find the rise: y₂ − y₁ = 11 − 3 = 8.
  3. Find the run: x₂ − x₁ = 6 − 2 = 4.
  4. Divide: m = 8 ÷ 4 = 2.
  5. Sanity-check by swapping the points: (3 − 11) ÷ (2 − 6) = (−8) ÷ (−4) = 2. Same answer — and the line does climb 2 for every 1 across, matching the picture.

A slope of 2 also makes a prediction you can test: a third point such as (3, 5) should sit on the same line, and it does — from (2, 3), one step right and two steps up lands exactly on (3, 5).

Worked Example 2: Slope of 2x + 3y = 6

Nothing here is labelled m, because the equation is in standard form. Two routes lead to the slope, and doing both gives you a built-in check.

  1. Shortcut: for ax + by = c the slope is −a/b. Here a = 2 and b = 3, so m = −2/3.
  2. Long way, to confirm: solve for y. Subtract 2x from both sides: 3y = −2x + 6. Divide every term by 3: y = −(2/3)x + 2. The coefficient of x is −2/3 — the same value.
  3. Cross-check with two points: when x = 0 the line gives y = 2, and when x = 3 it gives y = 0. The slope between (0, 2) and (3, 0) is (0 − 2) ÷ (3 − 0) = −2/3. ✓

The negative sign matches the graph: this line falls as you move right, dropping 2 units for every 3 units across.

Slope Outside the Classroom

Slope is a rate, and rates are everywhere. Road engineers express a hill’s steepness as a gradient — rise over run — and a “1 in 10” warning sign is a slope of 0.1. Builders set roof pitch and wheelchair-ramp angles from the same ratio, and building codes cap how steep a ramp may be. On a distance–time graph, slope is speed; on a price chart, it is the rate at which a cost is climbing. Even a plumber judging whether a drain falls enough for water to run is, without naming it, checking a slope.

Three Slope Mistakes to Watch For

  • Subtracting in mismatched order. (y₂ − y₁) over (x₁ − x₂) flips the sign and turns an uphill line downhill; whichever point you start with on top, start with the same point on the bottom.
  • Dividing run by rise. Slope is rise ÷ run, in that order — inverting the fraction turns a gentle slope of 1/4 into a cliff of 4.
  • Calling a vertical line slope zero. A vertical line has run 0, and dividing by zero is undefined, not zero; zero slope belongs to flat, horizontal lines.

Worked Example 3: The Full Equation of a Line Through Two Points

Slope is usually only half the question — the real goal is the line's equation. Take the points (1, 2) and (4, 8) and build the whole thing:

  1. Find the slope: m = (8 − 2) ÷ (4 − 1) = 6 ÷ 3 = 2. The line climbs two units for every unit it moves right.
  2. Use point-slope form: with the point (1, 2), y − 2 = 2(x − 1). Point-slope form is built for exactly this job — a slope and one point are all it asks for.
  3. Rearrange into slope-intercept form: y − 2 = 2x − 2, so y = 2x + 0 — the equation is simply y = 2x, and the intercept b is 0.
  4. Verify with the second point: at x = 4, y = 2 × 4 = 8 ✓ — the equation reproduces (4, 8), and at x = 1 it gives 2 ✓. An equation that fails this check has an arithmetic slip in step 1 or 3.

The same routine works for any pair of points: slope first, point-slope second, rearrange last. Keep the definitions beside you in our slope formula reference, measure how far apart the two points are with the distance formula calculator, and see the formal definition at Wolfram MathWorld.

Once you have the slope, solve for intercepts with our equation solver or simplify line expressions with the algebra calculator.

Frequently Asked Questions

What is the slope formula?

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

What does a zero or undefined slope mean?

Zero slope is a horizontal line (y = constant). Undefined slope is a vertical line (x = constant) — the run is zero, so division is impossible.

How do you find slope from an equation?

Put it in y = mx + b form; m is the slope. For standard form ax + by = c, the slope is −a/b.

Is this calculator free?

Yes — both modes are free with no sign-up, and all calculations run in your browser. Enter two points or a line equation, press Find Slope, and you get the slope value with the rise-over-run steps spelled out, including awkward cases like vertical lines where the slope is undefined.

What is the slope of the line through (2, 3) and (6, 11)?

Substitute into m = (y₂ − y₁)/(x₂ − x₁): rise = 11 − 3 = 8 and run = 6 − 2 = 4, so m = 8/4 = 2. The line climbs two units for every one unit it moves right. Swapping the points gives (3 − 11)/(2 − 6) = (−8)/(−4) = 2 — the same slope, as it must be.

How can slope tell whether two lines are parallel or perpendicular?

Lines with equal slopes are parallel and never meet. Lines whose slopes multiply to −1 are perpendicular: a line with slope 2 is perpendicular to one with slope −1/2, because 2 × (−1/2) = −1. This negative-reciprocal test is the quickest way to check for a right angle between two graphed lines.

How do I find the equation of a line through two points?

First find the slope, then use point-slope form and rearrange. Through (1, 2) and (4, 8): m = (8 − 2)/(4 − 1) = 2, then y − 2 = 2(x − 1), which expands to y = 2x. Check the answer by substituting the second point: 2 × 4 = 8, which matches.

What is point-slope form?

Point-slope form writes a line as y − y₁ = m(x − x₁), where m is the slope and (x₁, y₁) is any point on the line. It is the quickest way to build an equation when you know a slope and one point: with m = 2 through (1, 2) it gives y − 2 = 2(x − 1), which rearranges into the slope-intercept form y = 2x.

Related Tools & Guides

About the MathSolverFree Team

The MathSolverFree Team builds and maintains the calculators and step-by-step solvers on this site. Every tool is checked against worked textbook examples before it is published, and the method behind each solver is written out in full — in the worked examples on the page and in our guides — so you can see exactly how an answer is reached, not just the answer itself.

How we build and test our tools·More about the team