Midpoint Formula Calculator
The midpoint of a line segment is the point exactly halfway between its two endpoints, found by averaging the x-coordinates and averaging the y-coordinates. This calculator returns that midpoint and, as a bonus, the straight-line distance between the two points from the Pythagorean theorem. Enter the coordinates of both points and read the center and the length at once. It works with any real coordinates in any quadrant and is a staple of coordinate geometry, graphics, and mapping work.
Midpoint and distance formulas
midpoint x = (x1 + x2) / 2
midpoint y = (y1 + y2) / 2
distance = sqrt((x2 - x1)^2 + (y2 - y1)^2)
Example: (2,3) and (8,11) midpoint (5,7), distance 10
The midpoint averages the coordinates; the distance applies the Pythagorean theorem to the coordinate differences.
Coordinate geometry context
- The midpoint lies exactly halfway along the segment joining the points.
- The distance is the straight-line (Euclidean) length between the points.
- Negative coordinates and any quadrant are fully supported.
- If both points are identical, the midpoint equals that point and the distance is 0.
- Swapping the two points changes neither the midpoint nor the distance.
Midpoint formula: frequently asked questions
What is the midpoint formula?
The midpoint of two points (x1, y1) and (x2, y2) is the average of their coordinates: ((x1 + x2) / 2, (y1 + y2) / 2). The midpoint lies exactly halfway along the straight line segment joining the two points.
How is the midpoint different from the distance?
The midpoint is a point: the center of the segment. The distance is a length: how far apart the two points are, found with the Pythagorean theorem as the square root of the squared differences. This calculator returns both.
What is the distance formula?
The distance between (x1, y1) and (x2, y2) is the square root of (x2 minus x1) squared plus (y2 minus y1) squared. It is the straight-line (Euclidean) distance and follows directly from the Pythagorean theorem.
Can I use negative coordinates?
Yes. The formulas work for any real coordinates, positive or negative. Averaging and squaring handle signs correctly, so points in any quadrant are supported.
Where is the midpoint formula used?
It is used in geometry, computer graphics, mapping, and engineering to find centers of segments, place objects halfway between two locations, and bisect lines. Combined with the distance formula it underpins many coordinate-geometry problems.
Official sources
- NIST Digital Library of Mathematical Functions: DLMF home.
- NIST: National Institute of Standards and Technology.
Reviewed by the CalculatorHub team, edited by James Graham, 17 June 2026. See our methodology.