Coordinate geometry calculator — distance, midpoint, slope and equation at once

Enter two points and the calculator lists every basic property of the segment between them, from its length and midpoint to its slope and equation.

Live demo · real result from this tool
Distance10
Midpoint
(1, 5)
Slope
1.333333333
Line equation
y = 1.333333333x + 3.666666667
y-intercept
3.666666667
Angle of inclination
53.130102°

Processed on your device — nothing is uploaded.

How to use the coordinate geometry calculator

  1. Enter the first point in x₁ and y₁.
  2. Enter the second point in x₂ and y₂.
  3. Read the list: Distance, Midpoint, Slope, Line equation, y-intercept and Angle of inclination.

What it does and when to use it

Coordinate geometry homework often asks several questions about the same pair of points: how long is the segment, where is its middle, how steep is it, and what is its equation? This tool answers all of them from one input, so it works well as a quick check after you have solved a problem by hand. It is also handy for proofs, such as showing that the diagonals of a quadrilateral bisect each other (same midpoint) or that two sides are parallel (same slope).

Each property has its own tool with the full method shown: the distance calculator, the midpoint calculator and the slope calculator, which also gives the x-intercept and perpendicular slope.

How it works

With Δx = x₂ − x₁ and Δy = y₂ − y₁, the tool computes:

  • Distance: d = √(Δx² + Δy²)
  • Midpoint: ((x₁ + x₂)/2, (y₁ + y₂)/2)
  • Slope: m = Δy/Δx
  • y-intercept: b = y₁ − m·x₁, giving the line y = mx + b
  • Angle of inclination: arctan(m) in degrees

If Δx is 0 the line is vertical, and the tool writes x = x₁ instead of y = mx + b.

Worked examples

All properties, step by step. Points (1, −2) and (7, 6).

  1. Δx = 7 − 1 = 6 and Δy = 6 − (−2) = 8.
  2. Distance: √(36 + 64) = √100 = 10.
  3. Midpoint: ((1 + 7)/2, (−2 + 6)/2) = (4, 2).
  4. Slope: 8/6 = 4/3 ≈ 1.333333333.
  5. Intercept: b = −2 − (4/3)(1) = −10/3 ≈ −3.333333333.

The tool shows Midpoint: (4, 2), a distance of 10, Line equation: y = 1.333333333x − 3.333333333 and an angle of inclination of 53.130102°. In fraction form the line is y = (4/3)x − 10/3.

A horizontal segment. Points (−3, 5) and (2, 5) give distance 5, midpoint (−0.5, 5), slope 0 and the line y = 5.

A vertical segment. Points (4, 1) and (4, 7) give distance 6, midpoint (4, 4) and Line equation: x = 4, with the slope reported as undefined.

Limits and tips

  • Two dimensions only. For points in space use the 3D distance calculator.
  • If the two points are the same, the distance is 0 and the slope is reported as undefined.
  • No units: answers follow whatever unit your coordinates use.
  • Everything is worked out in your browser.

Frequently asked questions

Why does this tool not show the working?
It is a summary of all the results in one place. For step-by-step working, use the separate distance, midpoint and slope calculators, which print each line of the method.
What happens with a vertical line?
When both x values are equal, the slope is undefined, the equation is x = (that value) and there is no y-intercept. The angle of inclination is not shown in that case.
Why is the slope a long decimal like 1.333333333?
Results are shown to 10 significant figures. A slope of 1.333333333 is 4/3. You can turn decimals back into fractions with the decimal to fraction tool.
Can I use this to test whether three points are on one line?
Yes, in two runs. Enter points A and B, then A and C. If both slopes match, the three points are collinear.

Written by the ToolsRift team · Last updated

Pages are drafted with AI assistance and checked by automated tests. How we write and check pages.

Was this tool useful?

Report a problem

Start typing to search every tool.

↑ ↓ to moveEnter to openEsc to close