Curious Jr By PW

Distance Between Two Points - Formulas, Derivations with Examples

The distance between two points is the length of the straight line segment connecting them. In a 2D plane, it is calculated using the formula d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}, derived from the Pythagoras Theorem. The distance between two points represents the exact length of the straight line segment that links them. In the study of coordinate geometry, determining this length is a vital skill used to find the gap between two specific sets of coordinates on a plane. The most common method to calculate the distance between two points in a two-dimensional space is by using the standard formula: d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}. In this equation, (x_1, y_1) and (x_2, y_2) represent the specific positions of the two points on the coordinate grid. By understanding the distance between two points formulas for both 2D and 3D planes, you can accurately measure the spatial separation of objects in any mathematical environment.
authorImageNikita Aggarwal9 Apr, 2026
Distance Between Two Points - Formulas, Derivations with Examples

What is the Distance Between Two Points?

In geometry, the distance between two points refers to the length of the shortest path between them, which is always a straight line. This measurement is always non-negative, as distance cannot be less than zero.

Depending on where the points are located, we use different methods:

  • 1D Space: Distance on a horizontal or vertical number line.

  • 2D Space (XY Plane): Distance between points with (x, y) coordinates.

  • 3D Space (XYZ Plane): Distance between points in a three-dimensional environment.

Distance Between Two Points Formula

To find the length between coordinates, we use specific distance between two points formulas based on the dimensions involved.

1. Distance on a Number Line (1D)

If you have two points A(x_1) and B(x_2) on a single line, the distance is simply the absolute difference between them:

Formula: d = |x_2 - x_1|

2. Distance in a 2D Plane

For points P(x_1, y_1) and Q(x_2, y_2), we use the standard distance formula:

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

3. Distance from the Origin

If you are measuring the distance from the point (0,0) to (x, y):

Formula: d = \sqrt{x^2 + y^2}

Below are some more examples for practice:

Example 1: Distance from the Origin
Find the distance between P(0, 0) and Q(6, 8).
Using d = \sqrt{x^2 + y^2}:
d = \sqrt{6^2 + 8^2} = \sqrt{36 + 64} = \sqrt{100} = \mathbf{10\ units}.

Example 2: Points on a Horizontal Line
Find the distance between A(-2, 4) and B(5, 4).
Since the y-coordinates are the same, use the absolute difference of x:
d = |5 - (-2)| = |5 + 2| = \mathbf{7\ units}.

Example 3: Working with Negative Coordinates
Find the distance between C(-3, -1) and D(-7, -4).
d = \sqrt{(-7 - (-3))^2 + (-4 - (-1))^2}
d = \sqrt{(-4)^2 + (-3)^2} = \sqrt{16 + 9} = \sqrt{25} = \mathbf{5\ units}.

Example 4: Calculating a Diagonal Path
Find the distance between X(1, 1) and Y(4, 5).
d = \sqrt{(4 - 1)^2 + (5 - 1)^2}
d = \sqrt{3^2 + 4^2} = \sqrt{9 + 16} = \sqrt{25} = \mathbf{5\ units}.

Example 5: Points on a Vertical Line
Find the distance between M(3, -2) and N(3, 10).
Since the x-coordinates are the same, use the absolute difference of y:
d = |10 - (-2)| = |10 + 2| = \mathbf{12\ units}.

Example 6: Using the 3D Formula
Find the distance between R(1, 2, 3) and S(3, 4, 4).
d = \sqrt{(3 - 1)^2 + (4 - 2)^2 + (4 - 3)^2}
d = \sqrt{2^2 + 2^2 + 1^2} = \sqrt{4 + 4 + 1} = \sqrt{9} = \mathbf{3\ units}.

Example 7: Distance with Decimal Coordinates
Find the distance between J(0.5, 2) and K(3.5, 6).
d = \sqrt{(3.5 - 0.5)^2 + (6 - 2)^2}
d = \sqrt{3^2 + 4^2} = \sqrt{9 + 16} = \sqrt{25} = \mathbf{5\ units}.

Read More Half Angle Formula with Examples

Distance Between Two Points Derivations

Understanding the distance between two points derivations helps in retaining the formula for the long term. The 2D formula is actually a direct application of the Pythagoras Theorem.

Steps for Derivation:

  1. Assume two points P(x_1, y_1) and Q(x_2, y_2) on a coordinate plane.

  2. Draw a horizontal line from P and a vertical line from Q until they meet at a point R, forming a right-angled triangle PQR.

  3. The horizontal side (PR) length is (x_2 - x_1).

  4. The vertical side (QR) length is (y_2 - y_1).

  5. According to Pythagoras Theorem: PQ² = PR² + QR²

  6. Substituting the values: PQ^2 = (x_2 - x_1)^2 + (y_2 - y_1)^2.

  7. Taking the square root gives us the final distance between two points formulas.

Distance Between Two Points Examples

Let’s apply the logic to some real-world mathematical problems to see how these distance between two points examples work in practice.

Example 1: Basic 2D Distance

Find the distance between A(2, 3) and B(5, 7).

  • (x_1, y_1) = (2, 3)

  • (x_2, y_2) = (5, 7)

  • d = \sqrt{(5 - 2)^2 + (7 - 3)^2}

  • d = \sqrt{(3)^2 + (4)^2}

  • d = \sqrt{9 + 16} = \sqrt{25}

  • Distance = 5 units

Example 2: Negative Coordinates

Find the distance between P(-1, -1) and Q(2, 3).

  • d = \sqrt{(2 - (-1))^2 + (3 - (-1))^2}

  • d = \sqrt{(3)^2 + (4)^2}

  • d = \sqrt{9 + 16} = 5

  • Distance = 5 units

Read More - Perpendicular Bisector: Definition, Properties, and Practical Examples

How to Find Distance Between Two Points Using Coordinates?

Calculating the distance between two points is a systematic process. Whether you are working in a 2D or 3D plane, following these structured steps ensures accuracy in your results:

  1. Identify the Coordinates: Label your first point as A(x_1, y_1) and your second point as B(x_2, y_2).

  2. Apply the Formula: Input these values into the standard distance between two points formula: d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}.

  3. Simplify and Label: Solve the arithmetic within the square root and always express your final answer in "units".

Note: If you are working with a 3D plane, simply extend the calculation to include the z-axis usng the formula: d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2 + (z_2 - z_1)^2}.

Tips to Remember For Distance Between Two Points

  • Order doesn't matter: Because we square the differences (x_2 - x_1), the result is the same even if you calculate (x_1 - x_2).

  • Positive Result: Distance is a scalar quantity and is always positive.

  • Simplifying Radicals: Constantly try to simplify the square root at the end (e.g., \sqrt{8} becomes 2\sqrt{2}).

Make Maths Simple and Fun with CuriousJr

CuriousJr helps children develop a strong maths foundation by reducing fear and building confidence. Our Mental Maths online classes for students in Classes 1 to 8 focus on improving speed, accuracy, and logical thinking through easy techniques and interactive learning.

With our dual-mentor approach, students participate in engaging live sessions and get personalised support to clear their doubts after every class. Animated lessons, fun activities, and exciting challenges make maths easier to understand and more enjoyable.

Parents receive regular progress updates and review sessions, ensuring complete visibility into their child’s learning journey.

Book a demo class today and see how CuriousJr makes maths simple, engaging, and confidence-boosting for your child

Distance Between Two Points FAQs

What is distance between two points in coordinate geometry?

It is the length of the straight line segment that connects two specific sets of coordinates. It represents the shortest possible gap between those points.

Can the distance between two points be negative?

No. Since the distance between two points formulas involves squaring the differences and taking a principal square root, the result is always zero or positive.

How do you find the distance between two points with the same x-coordinate?

If the x-coordinates are identical, the points lie on a vertical line. You simply subtract the y-coordinates: d = |y_2 - y_1|.

What is the formula for the distance from the origin?

To find the distance from (0,0) to a point (x, y), you use the simplified formula d = \sqrt{x^2 + y^2}.
Curious Jr By PW
Curious Jr By PW

We understand that every student has different needs and capabilities, which is why we create such a wonderful and unique curriculum that is the best fit for every student.