Math

Midpoint of a Line Segment Calculator

Midpoint and length of a line segment between two points.

Enter your values

ⓘ Live results

Results
Midpoint
(2, 1)
Segment length
8.9443
Point 1
(-2, 3)
Point 2
(6, -1)

Quick answer

The midpoint averages the x-coordinates and averages the y-coordinates of the two endpoints.

M = ((x1+x2)/2, (y1+y2)/2)

How to use the Midpoint of a Line Segment Calculator

  1. 1Enter the coordinates of both endpoints.
  2. 2Average the x-values and the y-values separately to get the midpoint.
  3. 3The distance formula gives the full segment length for reference.

Worked example

Using the values the calculator loads with:

Inputs

  • Point 1 x-2
  • Point 1 y3
  • Point 2 x6
  • Point 2 y-1

Results

  • Midpoint(2, 1)
  • Segment length8.9443
  • Point 1(-2, 3)
  • Point 2(6, -1)

Frequently asked questions

Does this work in 3D?

This tool covers 2D points; extend the same averaging pattern with a z-coordinate for 3D.

What if the points are the same?

The midpoint equals that point and the segment length is zero.

About this calculator

Results are estimates for general information. For medical, legal, structural or financial decisions, confirm with a qualified professional.