Midpoint Calculator - Find Midpoint Between Two Points
Calculate the exact midpoint of a line segment in 2D or 3D space. Enter the coordinates of two points and get the midpoint coordinates instantly.
Enter the coordinates of two points (2D or 3D) to find the midpoint of the line segment connecting them.
Midpoint Calculator - Find Midpoint Between Two Points
Calculate the exact midpoint of a line segment in 2D or 3D space. Enter the coordinates of two points and get the midpoint coordinates instantly.
Point A
Point B
About the midpoint calculator
The midpoint of a line segment is the point that lies exactly halfway between the segment's two endpoints. It divides the segment into two equal halves and sits at the geometric centre of the segment. Finding midpoints is a foundational skill in geometry, and it comes up constantly in fields ranging from graphic design and game development to engineering, physics, and data visualisation.
The midpoint formula is one of the most elegant results in coordinate geometry. Given two points A = (x₁, y₁) and B = (x₂, y₂) in the plane, the midpoint M is simply the average of the x-coordinates paired with the average of the y-coordinates: M = ((x₁+x₂)/2, (y₁+y₂)/2). The reasoning is intuitive — to walk halfway from one number to another, you take their mean. The same logic extends directly to three dimensions: for points A = (x₁, y₁, z₁) and B = (x₂, y₂, z₂), the midpoint is M = ((x₁+x₂)/2, (y₁+y₂)/2, (z₁+z₂)/2).
This calculator supports both 2D and 3D midpoints. The 2D mode is ideal for plane geometry problems — finding the centre of a line segment on a graph, locating the midpoint of a room wall on a floor plan, or splitting a route into two equal legs. The 3D mode handles spatial problems: finding the midpoint of an edge on a 3D model, the centre of a line connecting two geographic locations given by latitude, longitude, and altitude, or the midpoint of a structural beam in engineering drawings.
Negative coordinates are handled correctly and transparently — the midpoint between (−4, 2) and (6, −8) is (1, −3), as straightforward as any other case. Decimal inputs work equally well. The calculator computes results with full floating-point precision and displays them rounded to a sensible number of decimal places.
Beyond the direct formula, midpoints have deeper mathematical significance. The midpoint theorem states that the segment connecting the midpoints of any two sides of a triangle is parallel to the third side and exactly half its length — a result used in triangle proofs, coordinate geometry, and tessellation. In vector notation, the midpoint of A and B is simply (A + B) / 2, which connects the formula naturally to linear interpolation (lerp), an operation used everywhere in computer graphics and animation to blend between two values or positions.
Whether you are solving homework problems, designing a layout, writing game logic, or working through an engineering challenge, this calculator gives you the midpoint in one step so you can focus on the bigger picture.
Midpoint calculator examples
Worked cases across 2D and 3D scenarios, including positive, negative, and zero coordinates.
| Points | Midpoint | Explanation |
|---|---|---|
| A(2, 4) and B(8, 10) | (5, 7) | ((2+8)/2, (4+10)/2) = (10/2, 14/2) = (5, 7). A straightforward 2D case with positive integers. |
| A(−4, 2) and B(6, −8) | (1, −3) | ((−4+6)/2, (2+(−8))/2) = (2/2, −6/2) = (1, −3). Midpoint correctly handles mixed signs. |
| A(0, 0) and B(10, 6) | (5, 3) | When one point is the origin, the midpoint is simply half the other point's coordinates. |
| A(1, 2, 3) and B(5, 8, 7) | (3, 5, 5) | 3D midpoint: ((1+5)/2, (2+8)/2, (3+7)/2) = (3, 5, 5). Same formula extended to three dimensions. |
| A(0, −3, 4) and B(6, 7, −2) | (3, 2, 1) | A 3D case with negative coordinates. Each axis is averaged independently: (0+6)/2=3, (−3+7)/2=2, (4+(−2))/2=1. |
How to use the midpoint calculator
- Choose whether your points are in 2D or 3D space using the coordinate space selector at the top.
- Enter the x, y (and z for 3D) coordinates of the first point in the fields labelled X₁, Y₁ (and Z₁).
- Enter the coordinates of the second point in the fields labelled X₂, Y₂ (and Z₂).
- Click Calculate. The midpoint coordinates appear immediately, along with the formula used.
- Click Reset to clear all fields and start a new calculation.
Midpoint calculator FAQ
What is the midpoint formula?
In 2D, the midpoint of (x₁, y₁) and (x₂, y₂) is ((x₁+x₂)/2, (y₁+y₂)/2). In 3D, you add a third component: ((x₁+x₂)/2, (y₁+y₂)/2, (z₁+z₂)/2). Each coordinate of the midpoint is simply the arithmetic mean of the corresponding coordinates of the two endpoints.
Can the midpoint have fractional coordinates?
Yes, and this is common. For example, the midpoint of (1, 0) and (2, 1) is (1.5, 0.5). Fractional midpoints are perfectly valid geometric points; they just do not land on integer grid intersections. The calculator displays them as decimals.
What if the two points are the same?
If both endpoints are identical, the midpoint is that same point. For example, the midpoint of (3, 5) and (3, 5) is (3, 5). This makes geometric sense: the 'line segment' has zero length, and its centre is the point itself.
Does order matter — does swapping the two points change the midpoint?
No. Since the formula averages each coordinate, swapping point A and point B gives the same midpoint. (x₁+x₂)/2 is identical to (x₂+x₁)/2 because addition is commutative.
How is the midpoint used in real life?
Midpoints appear in construction (finding the centre of a wall or beam), graphic design (centring elements), game programming (interpolating between positions), navigation (finding a halfway meeting point), and structural engineering (locating the centroid of a beam). They are also fundamental to bisecting angles and sides in geometric proofs.
Can I use the midpoint formula for more than two points?
The standard midpoint formula applies to exactly two points. To find the centre of a set of more than two points, you compute the centroid instead: average all x-coordinates, average all y-coordinates (and z if in 3D). The centroid reduces to the midpoint when there are exactly two points.