Slope Calculator
Find the slope of a line through two points, plus the line equation. Shows rise over run and the steps.
Slope Calculator
What Slope Means
Slope measures how steep a line is - how much it climbs for every step you take to the right. People call it “rise over run”: the rise is how far the line goes up, and the run is how far it goes across.
A bigger number means a steeper line. A positive slope climbs from left to right, a negative slope falls, a zero slope is flat, and a straight-up vertical line has no slope at all - its run is zero, and you cannot divide by zero. The graph by the calculator plots your two points and draws the rise and run as a little right triangle, so you can see exactly where the number comes from.
The Formula
How to Use It
- Enter the coordinates of point 1 (x1, y1) and point 2 (x2, y2).
- Read the slope and the line equation.
Worked Examples
| Point 1 | Point 2 | Slope | Line |
|---|---|---|---|
| (1, 1) | (3, 5) | 2 | y = 2x − 1 |
| (0, 0) | (4, 2) | 0.5 | y = 0.5x |
| (2, 5) | (6, 5) | 0 | y = 5 |
| (3, 1) | (3, 7) | undefined | vertical line |
FAQ
How do you calculate slope?
Divide the rise by the run: . For (1, 1) and (3, 5): .
What does a negative slope mean?
The line goes down from left to right. A positive slope goes up.
Why is the slope of a vertical line undefined?
The run (x2 − x1) is zero, and dividing by zero is undefined. A horizontal line has a slope of 0 instead, because the rise is zero.