Slope Calculator
Calculate slope from two points, a line equation, rise and run, or start and end elevations.
Slope Calculator: Two Points, Rise Over Run & Grade
Calculate slope from two points, a line equation, rise and run, or start and end elevations. You can also use a known slope to find rise, fall, horizontal run, or an end elevation.
Slope Calculator
Slope calculator input methods
How to calculate slope from two points?
Select Two points. Then use the diagram as a reference and enter the coordinates for the two points: X₁, Y₁, X₂, and Y₂. Then click View results.
How to calculate slope from a line equation?
Select Line equation and enter the coefficients A, B, and C from Ax + By + C = 0. Then click View results.
How to calculate slope from rise and run?
Select Rise + run. Enter the vertical change (rise / fall) and horizontal distance (run), using the same unit for both. Then click View results.
How to calculate slope from start and end elevations?
Select Start / end elevations. Enter the start elevation, end elevation, and horizontal distance. Then click View results.
Use a known slope to find rise, fall, run, or end elevation
How to calculate rise or fall from slope and horizontal distance?
Select Find rise / fall, then choose Horizontal distance + slope. Enter the horizontal distance and the known slope as a percentage or 1:N ratio. Choose Rise or Fall, then click View results.
How to calculate horizontal run from slope and vertical change?
Select Find horizontal distance, then choose Rise / fall + slope. Enter the vertical change and the known slope as a percentage or 1:N ratio. Then click View results.
How to calculate an end elevation from a known slope and distance?
Select Find rise / fall, then choose Start elevation + distance + slope. Enter the starting elevation, horizontal distance, known slope, and Rise or Fall direction. Then click View results to calculate the ending elevation.
Slope formulas and relationships
Slope describes how much a line rises or falls for a given horizontal run. The same geometry can be written as a decimal slope, percentage grade, angle, per mille, or 1:N ratio.
Slope formula: rise over run
For a measured rise or fall, divide the vertical change by the horizontal run. Multiply by 100 when you want slope as a percentage.
Two-point slope formula
For points (X₁, Y₁) and (X₂, Y₂), subtract the coordinates to get the vertical and horizontal changes, then divide ΔY by ΔX.
Line equation slope formula
For a line written as Ax + By + C = 0, the slope is m = −A/B. If B = 0, the line is vertical and its slope is undefined.
The calculator also rewrites the line as y = mx + b, where m is the slope and b is the y-intercept.
Slope percentage, angle, and 1:N ratio
These are different ways to describe the same slope. A 1:100 slope means 1 unit of vertical change for every 100 horizontal units. That is the same slope magnitude as 1%, 10‰, and about 0.57°.
To convert slope percentage to an angle, use angle = arctan(slope % / 100). In this calculator, 1:N means 1 vertical unit for every N horizontal units.
What do positive, negative, zero, and undefined slopes mean?
Read the line from left to right. A positive slope rises, a negative slope falls, a zero slope is horizontal, and a vertical line has an undefined slope because its horizontal change is zero.
Slope examples
The examples below show the same calculations by hand and the shortest way to reproduce them in this calculator.
Math examples
Example 1: slope from two points
For (2, 3) and (6, 11), ΔY = 11 − 3 = 8 and ΔX = 6 − 2 = 4. Therefore m = 8 / 4 = 2.
Try this example in the calculator: choose Calculate slope → Two points, then enter X₁ = 2, Y₁ = 3, X₂ = 6, and Y₂ = 11.
Example 2: slope from a line equation
For 2x − 4y + 6 = 0, A = 2 and B = −4. The slope is m = −2 / (−4) = 0.5.
Try this example in the calculator: choose Calculate slope → Line equation, then enter A = 2, B = −4, and C = 6.
Construction and site work examples
Example 3: driveway grade
A driveway rises 2 ft over a 40 ft horizontal run. Slope = 2 / 40 × 100 = 5%.
Try this example in the calculator: choose Calculate slope → Rise + run, then enter rise = 2 ft and run = 40 ft.
Example 4: 1:100 drainage fall
A 1:100 fall over 30 ft of horizontal run gives a fall of 0.3 ft. The same slope is 1%, 10‰, and about 0.57°.
Try this example in the calculator: choose Find rise / fall → Horizontal distance + slope → 1:N ratio, enter 30 ft and N = 100, and choose Fall.
Example 5: end elevation from grade
Start elevation = 344 ft, horizontal distance = 34 ft, and slope = 8.82% rising. The vertical change is about 3 ft, so the end elevation is about 347 ft.
Try this example in the calculator: choose Find rise / fall → Start elevation + distance + slope, enter 344 ft, 34 ft, and 8.82%, and choose Rise.
Slope in construction and site work
For driveways, roads, grading, and drainage, slope is usually based on a vertical rise or fall over a horizontal run. Survey and design drawings may instead give start and end elevations; their difference becomes the vertical change used in the same slope calculation.
When a target slope is already known, you can work backward to find the required rise, fall, horizontal run, or end elevation. That is why the calculator separates Calculate slope, Find rise / fall, and Find horizontal distance.
Planning note: these are geometry calculations, not design standards. Confirm drainage, accessibility, road grade, finished elevations, tolerances, and other project requirements before construction.
FAQ
How do I calculate with a 1:100, 1:10 or 1:2 slope?
If you know the horizontal distance and want the rise or fall, choose Find rise / fall, then Horizontal distance + slope, select 1:N ratio, and enter 100, 10 or 2. If you know the vertical change and want the horizontal distance, choose Find horizontal distance, then Rise / fall + slope, and use the same 1:N ratio input. In this calculator, 1:N means 1 vertical unit for every N horizontal units, so 1:100 = 1%, 1:10 = 10% and 1:2 = 50%.
What is the formula for horizontal run from slope and vertical change?
For a percentage slope, horizontal run = vertical change / (slope % / 100). For a 1:N ratio, horizontal run = vertical change × N.
How do I convert slope percentage to degrees?
Use angle = arctan(slope % / 100). A 10% slope is about 5.71°.
What is the formula for rise or fall from a known slope?
For percentage, rise or fall = horizontal run × slope % / 100. For a 1:N ratio, rise or fall = horizontal run / N.