Slope calculator
Type two points to get the slope with the working shown, the equation of the line in slope-intercept, point-slope and standard form, and a graph. Fractions stay exact.
- Write the slope formula: m = (y₂ − y₁) ÷ (x₂ − x₁)
- Put in the points (1, 2) and (5, 10): m = (10 − 2) ÷ (5 − 1)
- Work out the rise and run: m = 8 ÷ 4 = 2
- Find the y-intercept from y = mx + b: b = y₁ − m·x₁ = 2 − (2)(1) = 0
- The line is y = 2x. It rises from left to right.
How to find the slope
- 1Type the coordinates of two points. Fractions like 1/2 and decimals both work.
- 2Read the slope and the equation of the line. The result updates as you type.
- 3Follow the steps to see how it was worked out, and open the line in the calculator to explore it.
The slope formula
Slope is rise over run: how far the line goes up for each step to the right. Through the points (x₁, y₁) and (x₂, y₂):
For the points (1, 2) and (5, 10), the rise is 10 − 2 = 8 and the run is 5 − 1 = 4, so the slope is 8 ÷ 4 = 2. The line goes up 2 for every 1 across. It doesn’t matter which point you call first, as long as you use the same order on the top and bottom.
The four kinds of slope
| Slope | The line… | Example |
|---|---|---|
| Positive | Rises from left to right | y = 2x + 1 |
| Negative | Falls from left to right | y = −3x + 4 |
| Zero | Is horizontal | y = 5 |
| Undefined | Is vertical, because the run is zero | x = 2 |
From slope to the equation of the line
Once you have the slope, you can write the line in any form:
- Slope-intercept form, y = mx + b, shows the slope and where the line crosses the y-axis.
- Point-slope form, y − y₁ = m(x − x₁), is the quickest to write from a point and a slope.
- Standard form, Ax + By = C, uses whole numbers and is handy for systems of equations.
Slope in the real world
Road signs and ramps give slope as a percentage called grade: rise ÷ run × 100. A 5% grade rises 5 feet per 100 feet. A slope can also be given as an angle, found with the inverse tangent: a slope of 1 is 45°, and a slope of 0.05 is about 2.86°. In the US, the ADA limit for a wheelchair ramp is a slope of 1:12, about 8.33%.
Frequently asked questions
How do you find slope from two points?
What does a slope of 0 mean?
What is an undefined slope?
How do you find the slope from an equation?
How are the slopes of parallel and perpendicular lines related?
Related tools and guides
What m and b mean in y = mx + b, and how to use them.
Write a line from a point and a slope, then convert it.
A straight line: slope m, y-intercept b.
Solve linear systems by elimination, in exact fractions.
The equation of a tangent at any point, with the slope worked out.
Square, dot, isometric and polar grids as a PDF, in any size.
It opens instantly, with no account and nothing to install.