Mathematics calculator

Slope Calculator

Find slope, rise, run and the signed slope angle from two points on a coordinate plane.

Calculator inputs

Enter your values

Coordinate geometry
Calculated output

Result summary

Your result will appear here

Complete the required fields and select the calculate button.

What Is the Slope of a Line?

The slope of a line is the change in its y coordinate divided by the change in its x coordinate. For points (x₁, y₁) and (x₂, y₂), m = (y₂ − y₁)/(x₂ − x₁). It describes how much y changes for each one-unit increase in x.

This slope calculator returns the two-point slope, signed rise and run, direction and an arctangent angle. The x coordinates must differ. It does not draw a graph, calculate a y-intercept, return a percent grade or handle a vertical line as a finite slope.

How to Find Slope from Two Points

  1. Enter the first point’s x₁ and y₁ coordinates.
  2. Enter the second point’s x₂ and y₂ coordinates, keeping each x paired with its own y. All four values must be numeric within ±10^12.
  3. Make sure x₁ and x₂ are different, then select Calculate.
  4. Read Line slope, Rise, Run and Line direction. Check Entered points before interpreting the angle.

Rise is y₂ − y₁ and run is x₂ − x₁. Either can be negative. Reversing both points changes both differences’ signs and leaves the slope unchanged.

Slope displays two decimal places; rise and run round to eight, and the degree angle rounds to two. Direction uses the unrounded slope. A small increasing slope can display 0.00 while Direction remains Increasing, so the rounded main card does not alone establish an exactly horizontal line.

Slope, Rise, Run and Angle Formulas

Rise Δy = y₂ − y₁; run Δx = x₂ − x₁

Slope m = Δy/Δx, with Δx ≠ 0

Reported signed angle θ = arctan(m) × 180/π

Point-slope check: y − y₁ = m(x − x₁)

The division order is rise over run. Subtract the coordinates in the same point order in numerator and denominator. For a horizontal line, Δy = 0 and m = 0; for a vertical line, Δx = 0 and no finite slope exists.

The angle card reports the principal arctangent, between −90° and 90° for finite slopes. A negative slope therefore gives a negative angle, not a conventional 0°–180° line inclination. When a positive-orientation line angle is needed, a negative result can be represented by adding 180° outside the form.

Reference: OpenStax: Linear Functions. Two-point slope, signed rates of change and increasing/decreasing lines. Form limits, rounding and reporting conventions follow this calculator’s implementation.

Point Coordinates and Line Results

x₁ and y₁
Coordinates of the first point, with each value in its correct axis position.
x₂ and y₂
Coordinates of the second point; x₂ must differ from x₁.
Line slope
Featured rise/run, formatted to two decimal places.
Rise and run
Signed coordinate differences, rounded to eight decimals.
Signed slope angle
Signed principal arctangent result in degrees, not a directed travel bearing.
Line direction
Increasing, Decreasing or Horizontal from the unrounded slope.
Units
Slope is in y-units per x-unit. A physical angle interpretation requires comparable axis units and scaling.

Two-Point Slope Worked Example

Illustrative example. Find the slope through (−2, 5) and (4, −4).

Rise = −4 − 5 = −9 and run = 4 − (−2) = 6. Therefore m = −9/6 = −1.50. Direction is Decreasing and the signed arctangent angle is approximately −56.31°.

Independently write the line as y = −1.5x + 2 and substitute both points: it gives 5 at x = −2 and −4 at x = 4. Reversing the points gives rise 9 and run −6, preserving the same slope. The line equation is a hand check, not an extra output.

Calculation check. These illustrative values were checked independently against the formula and calculator response. Retain unrounded intermediate values when checking approximations.

Two-Point Slope Worked Example
QuantityValue
First point(−2, 5)
Second point(4, −4)
Rise; run−9; 6
Slope−1.50
Signed angle−56.31°
DirectionDecreasing

Vertical Lines, Reversed Points and Rounded Zero

A line’s slope does not depend on which point you enter first. Direction describes y as x increases, while the signs of rise and run depend on point order.

The angle is a signed principal arctangent. For the main example, −56.31° represents the same unoriented line direction as about 123.69° under a 0°–180° convention.

Vertical Lines, Reversed Points and Rounded Zero
CaseSlope or resultInterpretation
(−2,5) to (4,−4)−1.50Decreasing
Reverse the same points−1.50Same line; both differences reverse
(−2,5) to (4,5)0.00Exactly horizontal
(0,0) to (1,0.001)Displays 0.00Increasing before rounding
Same x, different yRejectedVertical; no finite slope

How to Interpret Positive, Negative and Zero Slope

A positive slope means y rises as x increases; a negative slope means y falls as x increases. This is a property of the line, not the direction you happen to travel between the entered points. Reversing the points does not change that classification.

Slope is a ratio, not automatically a percentage. A slope of −1.5 means y changes by −1.5 units per x-unit. A percent grade would be 100 times the ratio when the coordinate units represent matching vertical and horizontal lengths; that conversion is not an output here.

For axes with different meanings, such as cost versus time, slope has units such as currency per day. The computed arctangent of the numeric ratio is then not an intrinsic physical tilt. Large coordinates with tiny differences can also lose precision, so use meaningful scales and verify sensitive cases independently.

Common Coordinate Slope Mistakes

  • Dividing run by rise.
  • Subtracting the points in different orders on the two axes.
  • Swapping an x coordinate with its paired y coordinate.
  • Calling a vertical line’s slope zero.
  • Reading a negative signed angle as a 0°–180° inclination or travel bearing.
  • Treating 0.00 after rounding as proof that the line is horizontal.

Frequently Asked Questions

What is the two-point slope formula?

Use m = (y₂−y₁)/(x₂−x₁), provided x₂ differs from x₁. Keep the same point order in both subtractions.

Can rise or run be negative?

Yes. Their signs depend on point order. Slope can be positive or negative because it is their signed ratio.

Does reversing the points change slope?

No. It reverses both rise and run, leaving their ratio unchanged. The line’s Increasing or Decreasing classification stays the same.

What is the slope of a horizontal line?

It is zero because the y coordinates are equal and the x coordinates differ.

Why are equal x coordinates rejected?

A vertical line has zero run and no finite slope. Coincident points also fail to define a unique line through two distinct positions.

Why can the angle be negative?

The form uses the principal arctangent of slope, which gives a signed angle between −90° and 90°. It is not a directed bearing or a 0°–180° line-angle convention.

Is slope already a percentage?

No. It is a ratio in y-units per x-unit. For matching vertical/horizontal length units, percent grade is 100 times that ratio, a separate conversion.

Why can 0.00 appear with Direction Increasing?

The featured slope rounds to two decimals while direction uses the unrounded value. A small positive slope can therefore display as 0.00 without being exactly horizontal.

Sources and References