All tools · 📊 Math

📈 Slope Calculator

Enter two points (x₁, y₁) and (x₂, y₂) — we compute the slope m = (y₂ − y₁)/(x₂ − x₁), the y-intercept b, the line equation y = mx + b, the distance between the points, and the midpoint.

Loading tool…

Examples

Simple line
Input(0,0) and (4,8)
Outputm=2, b=0, y=2x · distance 8.94 · midpoint (2,4)
Negative slope
Input(0,5) and (3,-1)
Outputm=-2, b=5, y=-2x+5
Vertical line
Input(2,1) and (2,7)
OutputSlope undefined — vertical line x=2

Frequently asked questions

What is the slope formula?

m = (y₂ − y₁) / (x₂ − x₁). Vertical lines (x₁ = x₂) have undefined slope.

How to find y-intercept from two points?

Once you know m, plug a point in: b = y − mx.

Distance formula?

√((x₂−x₁)² + (y₂−y₁)²). Pythagorean theorem applied to the right triangle the two points form.

About this tool

Slope Calculator runs entirely in your browser using standard Web APIs. No data is sent to any server. The source for this tool is in our public GitHub repository.

Related tools

← All 96 tools

Why this tool

vs typical free web-tool sites

1vwTypical free site
PriceFreeFree
Signup requiredNoOften (for premium features)
Ads inside the toolNoYes (banner + video)
Data sent to serverNo (browser-only)Yes (inputs analyzed for ads)
Total tools96Often <20 or scattered across sites
Bookmarkable URL per toolYesMixed
Loads in under 1sYes (static)Often slow (ad tracking)
MultilingualEN / ES / PT / FR / DEUsually EN only
Open sourceYesNo