Calculate the slope of any line. Enter the x and y coordinates of any two points along a line to calculate the slope of the line. You can also leave exactly one field blank to solve for a missing coordinate or the slope.
- All Math and Numbers Calculators
- All Slope Calculators
- Distance Between Points Calculator
- Midpoint Calculator
- Interpolation Calculator
Slope Formula
The slope of a line can be calculated through the following formula:
slope = (y₂ - y₁) / (x₂ - x₁)
- y₂ = y coordinate of point 2
- y₁ = y coordinate of point 1
- x₂ = x coordinate of point 2
- x₁ = x coordinate of point 1
Slope Definition
Another word for slope is gradient. The slope (or gradient) of a line is the rate of change of y with respect to x, meaning \( \Delta y / \Delta x \). The slope is also often called rise over run: the Y-axis change is the vertical “rise” and the X-axis change is the horizontal “run.” The steeper the line, the larger the absolute value of the slope (for non-vertical lines). A line with slope close to 0 is relatively flat, and a perfectly vertical line has an undefined slope because the run is 0.
How to Calculate Slope
Below is an example of how you might calculate the slope of a line with limited information. Let's assume you are given the coordinates (2,3) and (4,5).
- First, you need to subtract y2-y1. Through this, you get 2.
- Next, you need to subtract X2-X1. Through this, you get 2.
- Now divide the change in y by the change in x. 2/2=1. Your slope is equal to 1.
- The last step is to analyze your results.
FAQ
A slope is considered the change in vertical distance divided by the change in horizontal distance.

