Midpoint Calculator

Find the midpoint between two points instantly. Enter the coordinates of A and B and the midpoint calculator applies the midpoint formula, showing each step, the length of the segment, its slope and the equation of the perpendicular bisector, with a graph. It works in 2D and 3D. You can also work backwards to find a missing endpoint when you know one end and the midpoint, or find the point that divides a segment in a given ratio using the section formula.

  • 100% free
  • No sign-up
  • Private & local
  • Works on mobile

Point A

Point B

Graph

Working

Private by design: every calculation runs locally in your browser. Nothing you type is sent to a server or stored by us.

The Midpoint Formula

The midpoint of a line segment is the point exactly halfway between its two endpoints. You find it by averaging the coordinates:

M = ( (x₁ + x₂) ÷ 2 , (y₁ + y₂) ÷ 2 )

Example: the midpoint of A(2, 3) and B(8, −5) is ((2 + 8) ÷ 2, (3 + (−5)) ÷ 2) = (5, −1). In three dimensions, you simply average the z-coordinates as well: M = ((x₁ + x₂)/2, (y₁ + y₂)/2, (z₁ + z₂)/2).

How to Use the Midpoint Calculator

  1. Choose what to find: the midpoint, a missing endpoint, or a point that divides the segment in a ratio.
  2. Tick 3D if your points have z-coordinates.
  3. Enter the coordinates. Negative numbers and decimals are fine.
  4. Read the answer, shown as exact fractions where possible, with the working and a graph.

Finding a Missing Endpoint

If you know one endpoint A and the midpoint M, the other endpoint is B = 2M − A. For each coordinate: double the midpoint and subtract the known endpoint. For A(1, 4) and M(3, −2): B = (2 × 3 − 1, 2 × (−2) − 4) = (5, −8). This is a common exam question, and it's easy to get backwards, so the calculator shows the check.

Dividing a Segment in a Ratio (Section Formula)

The midpoint divides a segment in the ratio 1 : 1. More generally, the point P that divides AB so that AP : PB = m : n is:

P = ( (n·x₁ + m·x₂) ÷ (m + n) , (n·y₁ + m·y₂) ÷ (m + n) )

For A(2, 3), B(8, −5) and the ratio 1 : 2, P = ((2·2 + 1·8) ÷ 3, (2·3 + 1·(−5)) ÷ 3) = (4, 1/3). That's one third of the way from A to B. The section formula is used for trisecting segments, finding centroids and in computer graphics for interpolation.

Related Results

QuantityFormulaFor A(2, 3), B(8, −5)
Midpoint((x₁+x₂)/2, (y₁+y₂)/2)(5, −1)
Length√((x₂−x₁)² + (y₂−y₁)²)√(36 + 64) = 10
Slope(y₂−y₁) ÷ (x₂−x₁)−8/6 = −4/3
Perpendicular bisectorThrough M, slope −1/my = 3/4 x − 19/4

The perpendicular bisector passes through the midpoint at a right angle to the segment. Every point on it is the same distance from A and B, which is why it's used to find the centre of a circle through three points.

Midpoints on a Number Line

The same idea works in one dimension: the midpoint between two numbers is their average. Halfway between 4 and 18 is (4 + 18) ÷ 2 = 11, and halfway between −6 and 10 is 2. This is useful for finding the middle of a date range, a price range or a measurement, for example the centre of a shelf or a board you want to cut in half.

Where Midpoints Are Used

  • Geometry: medians of triangles join a vertex to the midpoint of the opposite side, and they meet at the centroid.
  • Circles: the centre of a circle is the midpoint of any diameter.
  • Maps and navigation: finding a halfway meeting point between two locations on a grid map.
  • Computer graphics: subdividing lines and shapes, and interpolating positions in animation.
  • Construction and design: centring windows, shelves, pictures and fixtures.

Common Mistakes

The most frequent error is subtracting the coordinates instead of adding them, which gives half the distance rather than the midpoint. Another is mixing up x and y values between the two points. Sign errors with negative coordinates are also common: (−4 + 2) ÷ 2 = −1, not 3. The step-by-step working shows each coordinate separately to help you check your own answer.

Frequently Asked Questions

How do you find the midpoint of two points?

Add the x-coordinates and divide by 2, then add the y-coordinates and divide by 2.

Can the midpoint have fractions?

Yes. If a sum is odd, the coordinate is a half, such as (3 + 4) ÷ 2 = 7/2 = 3.5.

Does it work in 3D?

Yes. Tick 3D and average the z-coordinates too.

How do I find an endpoint from the midpoint?

Choose "A missing endpoint" and enter A and M. The calculator uses B = 2M − A.

What is the midpoint used for?

Bisecting segments, finding circle centres and diameters, perpendicular bisectors and centroids, and in design and mapping.