Calculate the slope of a line between two points instantly. Find slope, equation, distance, and angle with step-by-step solutions. Free online slope calculator with interactive graph and formula guide.
So you need to find the slope between two points. Maybe it's for homework. Maybe you're trying to figure out how steep a ramp needs to be. Either way, you're in the right place.
Our slope calculator does the math for you. Just plug in two points, and it'll spit out the slope, the equation of the line, and even show you a graph. But here's the thing - understanding what slope actually means is way more useful than just getting the answer.
Let's break it down.
Slope is just a fancy word for "steepness." That's it. Think about a hill. Some hills are super steep (you'd need a rope to climb them). Others are gentle (you could walk up them without breaking a sweat). Slope measures that steepness with a number.
In math terms, slope tells you how much a line goes up or down as you move from left to right. It's the "rise" (vertical change) divided by the "run" (horizontal change).
Rise over run. That's the golden rule.
Here's the formula everyone talks about:
m = (yβ - yβ) / (xβ - xβ)
Looks scary? It's not. Let's translate:
So you're basically asking: "For every step I take to the right, how many steps do I go up or down?"
Say you have two points: (1, 2) and (4, 8).
Point 1: xβ = 1, yβ = 2
Point 2: xβ = 4, yβ = 8
Plug it in:
m = (8 - 2) / (4 - 1)
m = 6 / 3
m = 2
So the slope is 2. That means for every 1 step you move to the right, you go up 2 steps. Pretty steep!
Here's where things get interesting. Not all slopes are the same. Here's what each type tells you:
If your slope is a positive number (like 2, 0.5, or 100), the line goes up as you move right. Think of a ski slope that goes uphill. The bigger the number, the steeper it is.
If your slope is negative (like -3 or -0.25), the line goes down as you move right. Think of a slide at a playground. The more negative the number, the steeper the drop.
If your slope is 0, the line is perfectly horizontal. It's like walking on flat ground. No rise at all. Just a straight line left to right.
This one confuses everyone. If your slope is "undefined," it means the line is vertical. Straight up and down. Why is it undefined? Because you'd be dividing by zero (the run is 0), and math doesn't allow that.
Using our calculator is stupidly simple:
That's it. You'll get:
Slope isn't just for math class. It's everywhere:
Roofers talk about "pitch" all the time. A roof with a 4/12 pitch means it goes up 4 inches for every 12 inches of horizontal distance. That's slope. A steeper roof sheds snow better but is harder to walk on.
Ever seen a sign that says "6% grade"? That's slope. A 6% grade means the road goes up (or down) 6 feet for every 100 feet of horizontal distance. Too steep and trucks can't make it. Too flat and water doesn't drain.
Ski runs are rated by steepness. Green circles are gentle slopes (small slope value). Black diamonds are steep (large slope value). Ski resorts literally use the slope formula to classify their runs.
Building codes say wheelchair ramps can't be too steep. The maximum slope is usually 1:12 (rise of 1 inch for every 12 inches of run). That's a slope of about 0.083.
After looking at hundreds of Reddit posts, here are the biggest mistakes:
It doesn't matter which point you call Point 1 and which you call Point 2. BUT you have to be consistent. If you use (xβ - xβ) for the bottom, you MUST use (yβ - yβ) for the top. Don't mix and match.
Pro tip: Always subtract the first point from the second point. That way you won't get confused.
If one of your y-values is negative, be careful. Subtracting a negative is the same as adding. Example: yβ - yβ where yβ = -3 means you're doing yβ - (-3) = yβ + 3.
They're not. Zero slope = horizontal line (flat). Undefined slope = vertical line (straight up). A horizontal line has a slope of 0. A vertical line has no slope at all.
Once you have the slope, you can write the equation of the line as y = mx + b. The "m" is your slope, and "b" is the y-intercept (where the line crosses the y-axis).
To find "b," just plug in one of your points. If your slope is 2 and you use the point (1, 2):
2 = 2(1) + b
2 = 2 + b
b = 0
So the equation is y = 2x.
Another way to write the equation is y - yβ = m(x - xβ). This is super useful when you know the slope and one point but not the y-intercept.
Two lines are parallel if they have the same slope. Two lines are perpendicular if their slopes are negative reciprocals of each other (like 2 and -1/2).
The concept of slope goes back to ancient Greece. But the modern way we think about it (with coordinates and formulas) came from RenΓ© Descartes in the 1600s. He's the guy who came up with the coordinate plane (the x and y axes). Before him, people thought about steepness in a much more vague way.
So next time you calculate slope, you're using math that's over 400 years old. Pretty cool, right?
Problem: My answer is a fraction. Is that okay?
Answer: Totally fine. Slope can be any number, including fractions. 1/2 means you go up 1 for every 2 you go right.
Problem: I got a negative slope but my line looks like it's going up.
Answer: Double-check your points. If the line goes up as you move right, the slope should be positive. You probably mixed up the order of your points.
Problem: My calculator says "undefined" but I don't know why.
Answer: Look at your x-coordinates. Are they the same? If xβ = xβ, you have a vertical line. That means the slope is undefined.
The slope formula is m = (yβ - yβ) / (xβ - xβ). It's just the change in y divided by the change in x. Think of it as "rise over run."
Take your two points, label them (xβ, yβ) and (xβ, yβ), then plug them into the formula. Subtract the y-values to get the rise. Subtract the x-values to get the run. Divide rise by run. That's your slope.
A slope of 0 means the line is perfectly horizontal. It's flat. No matter how far you move left or right, the y-value stays the same.
An undefined slope means the line is vertical. It goes straight up and down. The x-coordinates of both points are the same, so you're dividing by zero, which isn't allowed in math.
Absolutely. Slope can be any real number. A fraction like 2/3 just means you go up 2 units for every 3 units you move to the right. It's still a valid slope.
Positive slope means the line goes uphill as you move right. Negative slope means it goes downhill. Think of it like this: positive = climbing, negative = descending.
Pick any two points on the line. Count how many units you go up (or down) to get from one point to the other. That's the rise. Then count how many units you go right. That's the run. Divide rise by run.
Most likely you're mixing up the order of your points or messing up the signs. Make sure you subtract the first point from the second point consistently. Also watch out for negative numbers - subtracting a negative is the same as adding.
Slope-intercept form is y = mx + b. The "m" is the slope and the "b" is the y-intercept (where the line crosses the y-axis). It's the most common way to write the equation of a line.
Slope is used everywhere. Roofers use it to measure roof pitch. Engineers use it to design roads and ramps. Ski resorts use it to rate trail difficulty. Even your driveway has a slope so water drains off it.
The slope of a horizontal line is 0. The line doesn't go up or down at all. It's perfectly flat.
The slope of a vertical line is undefined. The line goes straight up and down, so the run is 0. You can't divide by zero, so the slope doesn't exist as a number.
If you have the slope and one point, plug them into y = mx + b. Solve for b. For example, if m = 2 and the point is (1, 3), then 3 = 2(1) + b, so b = 1.
In math, they're the same thing. "Gradient" is just a fancier word for slope. In geography, gradient might refer to the steepness of a hill or road, but the math is identical.
Yes! Lines with the same slope are parallel. They never intersect. Think of railroad tracks - they have the same slope and run side by side forever.