Complete guide
Slope calculator with two points, angle and line equation
Enter two distinct points. Calculator24 reports rise, run, slope, direction angle, intercept and both point-slope and slope-intercept equations when defined.
How to find slope
Subtract coordinates in the same order and divide the y difference by the x difference.
m=(y₂−y₁)/(x₂−x₁)Positive, negative and zero slope
A positive slope rises left to right, a negative slope falls, and zero slope is horizontal.
Vertical lines
If the run is zero, division by zero is impossible. The slope is undefined and the equation is x equal to the shared x-coordinate.
Line equations
Point-slope form works directly from a point and slope. Solving for y gives slope-intercept form when the line is not vertical.
y−y₁=m(x−x₁)y=mx+bWorked two-point example
From (−3,−4) to (3,0), rise is 4 and run is 6, so m=4/6=2/3.
Angle interpretation
atan2(rise,run) preserves quadrant and returns a directed angle. A line direction may also be described by an equivalent angle 180 degrees away.
Slope classifications
| Slope | Line direction |
|---|---|
| m>0 | Rises |
| m<0 | Falls |
| m=0 | Horizontal |
| Undefined | Vertical |
Frequently asked questions
What is rise over run?
It is (y₂−y₁)/(x₂−x₁).
Why is vertical slope undefined?
Its run is zero, so the ratio divides by zero.
Does point order change slope?
No. Reversing points changes both difference signs.
What is the y-intercept?
It is b=y₁−mx₁ for a nonvertical line.
Can slope be zero?
Yes. A horizontal line has zero slope.
Is slope the same as angle?
No. They are related by m=tan(angle) for nonvertical lines.
What to keep in mind
When x₁=x₂, the line is vertical, slope is undefined and the equation is x=x₁. Angle is reported from the positive x-axis.
Results display up to 8 decimal places; exported numbers preserve calculation precision. This is a calculation summary, not an official certificate.