Slope Calculator

Slope between two points — plus intercept, equation, angle and point-slope form.

100% FreeNo sign-upPrivate — runs in your browser

Enter any two different points. The line through them is worked out instantly.

Show exact fraction
Show the slope as a reduced fraction (e.g. 4/3) when both coordinates are whole numbers.
—

Slope (m)

—
Y-intercept (b)
—
Angle with x-axis
—
Slope-intercept form
—
Point-slope form
—
Parallel slope
—
Perpendicular slope
—
Distance between points
—
Direction
—
Copied to clipboard

How to use this tool

1
Enter the first point

Type the x and y coordinates of your first point, for example (0, 0).

2
Enter the second point

Type the second point, for example (3, 4). The two points must be different.

3
Read the slope and equations

The slope, intercept, both equation forms, angle, parallel and perpendicular slopes appear instantly.

4
See the exact fraction

Switch on “Show exact fraction” to see the slope as a reduced fraction when both coordinates are whole numbers.

Formula & worked example

Slope m = (y₂ − y₁) ÷ (x₂ − x₁) = rise ÷ run. Slope-intercept form: y = mx + b, where b = y₁ − m·x₁. Point-slope form: y − y₁ = m(x − x₁). Angle θ = arctan(m).

Points (0, 0) and (3, 4): rise = 4 − 0 = 4, run = 3 − 0 = 3, so slope m = 4/3 ≈ 1.3333. The y-intercept is 0, the equation is y = 1.3333x, the angle with the x-axis is about 53.13°, and the perpendicular slope is −3/4.

Limitations — read this before you rely on it

This calculator works with straight lines only — it does not fit curves or find the slope of a function at a point (that needs calculus). A vertical line has no defined slope, and very large coordinates may lose a little decimal precision. Results are rounded to 4 decimal places for display.

Frequently asked questions

Subtract the y-values and divide by the difference in x-values: m = (y₂ − y₁) ÷ (x₂ − x₁). Enter the two points and the calculator does it, including the intercept and equation.

The slope-intercept form is y = mx + b, where m is the slope and b is where the line crosses the y-axis. The point-slope form is y − y₁ = m(x − x₁) for a line through a known point.

A positive slope rises left to right; a negative slope falls left to right; a zero slope is a flat horizontal line. A vertical line has no defined slope because you would divide by zero.

Parallel lines share the same slope. A perpendicular line has the negative reciprocal slope: flip the fraction and change the sign. For slope 2, the perpendicular slope is −1/2.

Use the angle form: angle = arctan(m). A slope of 1 makes 45°, a slope of 0 makes 0°, and a vertical line makes 90° with the x-axis.