What Is Slope?
Slope measures how steep a line is and which way it tilts. This guide covers what that means, the formula, the four types, and why the same idea turns up on road signs and roof plans.
Definition
Slope is a number that describes how steep a straight line is and which direction it tilts. It is written m, and in most of the world it is called the gradient — the same thing under a different name.
The definition is a ratio: for every unit you move to the right, how far does the line move up or down? A slope of 3 climbs three units per step right. A slope of −0.5 falls half a unit. A slope of 0 goes nowhere vertically at all.
That is the whole idea. Everything else on this page is a consequence of it.
The slope formula
To measure the ratio you need two points on the line. Then:
The rise is the vertical change and the run is the horizontal change. The Greek letter Δ (delta) is just shorthand for "the change in".
Any two points on the same straight line give the same slope — that is what makes a line straight. Pick the two with the friendliest numbers.
The four types of slope
| Type | Value | The line | Example |
|---|---|---|---|
| Positive | m > 0 | Rises left to right | y = 2x + 1 |
| Negative | m < 0 | Falls left to right | y = −3x + 4 |
| Zero | m = 0 | Perfectly horizontal | y = 5 |
| Undefined | no value | Perfectly vertical | x = 5 |
The last two are the ones to get straight. A horizontal line has zero rise, so m = 0 ÷ run = 0 — a real number. A vertical line has zero run, so the formula asks you to divide by zero, which has no answer at all. Its slope is undefined, not infinite and certainly not zero.
Steepness lives in the size of the number, direction in the sign. A slope of −5 is steeper than a slope of 2, even though −5 is the smaller number.
Try it on your own numbers
Enter two points and press the button — the answer holds still while you read.
Slope, angle and percent grade
Slope, the angle of incline and percent grade are three ways of stating the same steepness. Trigonometry connects them:
| Slope | Angle | Grade | Ratio |
|---|---|---|---|
| 0.05 | 2.86° | 5% | 1:20 |
| 0.0833 | 4.76° | 8.33% | 1:12 |
| 0.5 | 26.57° | 50% | 1:2 |
| 1 | 45° | 100% | 1:1 |
| 2 | 63.43° | 200% | 2:1 |
Notice that percent and degrees do not scale together. Doubling the grade does not double the angle, and a 100% grade is 45°, not vertical.
Parallel and perpendicular lines
- Parallel lines have equal slopes. They climb at the same rate, so they never meet. y = 2x + 1 and y = 2x − 7 are parallel.
- Perpendicular slopes multiply to −1. To get one from the other, flip the fraction and change the sign: the perpendicular of 2/3 is −3/2.
The one exception is the horizontal/vertical pair. They are perpendicular, but 0 and "undefined" cannot be multiplied, so the rule is stated separately for them.
Slope outside the classroom
Once you can read a slope, you see it everywhere — usually wearing a different name.
- Road signs. A "6% grade" warning sign is a slope of 0.06.
- Roofing. A "6:12 pitch" is a slope of 0.5 — see the roof pitch calculator.
- Accessibility. A 1:12 ramp is the steepest the ADA allows — a slope of 0.0833.
- Plumbing. "A quarter inch per foot" of drain fall is a slope of about 0.021.
- Physics. On a distance-time graph the slope is the speed; on a velocity-time graph it is the acceleration.
- Data and finance. The slope of a trend line is the rate of change — dollars per month, degrees per decade.
In every one of those, someone divided a rise by a run.
What is slope in simple terms?
How steep a line is, and which way it leans. It is the rise (vertical change) divided by the run (horizontal change) between any two points on the line.
What are the four types of slope?
Positive (the line rises), negative (it falls), zero (horizontal), and undefined (vertical).
What is the slope of a horizontal line?
Zero. There is no vertical change, so the rise is 0 and 0 divided by any run is 0.
What is the slope of a vertical line?
Undefined. The run is zero and division by zero has no answer. This is different from a slope of zero, which describes a horizontal line.
Is slope the same as gradient?
Yes. Gradient is the usual term outside the United States for exactly the same quantity.
Can slope be a fraction?
Yes, and it usually is. A slope of 3/4 means the line rises 3 units for every 4 units across, which is also a handy instruction for graphing it.
Which slope is steeper, 2 or -5?
The -5 line. Steepness is the size of the number regardless of sign; the sign only tells you the direction of the tilt.