Slope Calculator

Slope, y-intercept and incline angle of the line through two points.

Equation used
m = (y_2 - y_1)/(x_2 - x_1); y = mx + b

Frequently Asked Questions

Why does the calculator say the slope is undefined for my two points?

That happens when both points share the same x-coordinate, making the line vertical. Slope is Δy/Δx, and dividing by Δx = 0 is undefined — the calculator detects this and reports the line as vertical instead of showing a slope.

What does the Angle value represent?

It's the line's angle of incline in degrees, found from arctan(slope). A positive angle means the line rises left to right; a negative angle means it falls. It ranges from just under +90° to just under −90°.

How is the y-intercept calculated?

Once the slope (m) is known, the y-intercept (b) is solved from the line equation using either point: b = y1 − m×x1. That's why the y-intercept only appears when a slope could be computed (not for vertical lines).