2D Distance Calculator: Straight Line Distance Between Points

Written by:
PK

Here is a 2D distance formula calculator, which computes the straight line (Euclidean) distance between two points in two dimensions.

2D Distance Calculator

Formula for 2D Euclidean distance

The formula for two-dimensional distance is:

d=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}

Where:

  • d: the distance between the two points (the hypotenuse)
  • x1, y1: the x and y coordinates of point 1
  • x2, y2: the x and y coordinates of point 2

Example distance calculation

Say you have 2 points (x, y): (4, 9) and (0, 6).

d=\sqrt{(0-4)^2+(6-9)^2}=\sqrt{16+9}=\sqrt{25}=5

The distance between these points is 5.

Using the 2D distance calculator

Enter the X and Y coordinates for both points in the Point 1 and Point 2 fields. The distance will calculate automatically.

Related calculators

      

PK

PK started DQYDJ in 2009 to research and discuss finance and investing and help answer financial questions. He's expanded DQYDJ to build visualizations, calculators, and interactive tools.

PK lives in New Hampshire with his wife, kids, and dog.

Don't Quit Your Day Job...

DQYDJ may be compensated by our partners if you make purchases through links. See our disclosures page. As an Amazon Associate we earn from qualifying purchases.
Sign Up For Emails
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram