Distance from Point to Plane Calculator
Enter the equation of a plane (Ax + By + Cz + D = 0) and the coordinates of a point to find the exact perpendicular distance between them. Switch to the normal-vector mode if you know a direction vector and a point that lies on the plane instead. Both modes show the full step-by-step working so you can follow the arithmetic.
Formula
Worked example
Find the distance from P = (1, 1, 1) to the plane x + 2y + 2z - 6 = 0. Numerator: |1(1) + 2(1) + 2(1) - 6| = |1 + 2 + 2 - 6| = |-1| = 1. Denominator: sqrt(1^2 + 2^2 + 2^2) = sqrt(1 + 4 + 4) = sqrt(9) = 3. Distance = 1 / 3 = 0.333...
What is the distance from a point to a plane?
In three-dimensional space, the distance from a point to a plane is defined as the length of the shortest line segment connecting the point to any point on the plane. That shortest segment is always perpendicular to the plane, so the distance is also called the perpendicular distance or the orthogonal distance. Geometrically, you can picture it by imagining a balloon inflated from the point until it just touches the plane: the radius at the moment of contact is the distance. Because the plane extends infinitely in every direction, the perpendicular foot is always well-defined as long as the plane itself is non-degenerate (that is, A, B, and C are not all zero).
The formula and where it comes from
A plane in 3D is described by the equation Ax + By + Cz + D = 0. The vector (A, B, C) is the normal vector of the plane, perpendicular to every direction that lies within the plane. To find the distance from a point P = (x0, y0, z0), you project the vector from any point on the plane to P onto the unit normal. That projection equals (A*x0 + B*y0 + C*z0 + D) / sqrt(A^2 + B^2 + C^2). Taking the absolute value makes the result always non-negative regardless of which side of the plane P is on. The signed version - without the absolute value - tells you which side the point is on: positive means on the same side as the normal vector, negative means the opposite side.
Using the normal-vector mode
If you know the normal direction and one point on the plane rather than the coefficients, switch to "Normal vector + point on plane." The calculator derives D automatically using D = -(nx*px + ny*py + nz*pz), then applies the same distance formula. This is useful in computer graphics, physics simulations, and robotics where planes are often described by a surface normal and a reference point rather than an implicit equation.
Practical applications
Point-to-plane distance appears in computer graphics (collision detection, ray-plane intersection, shadow mapping), mechanical engineering (checking whether a manufactured part lies within tolerance of a design surface), machine learning (support vector machines use signed point-to-hyperplane distance as the classification margin), robotics (workspace boundary checks), and pure mathematics (analytic geometry proofs). The formula generalises to n dimensions by using n coordinates for the point and n coefficients for the hyperplane.
Common special cases
| Plane | Equation form | Distance from point (x0, y0, z0) |
|---|---|---|
| xy-plane | z = 0 (i.e., 0x + 0y + z + 0 = 0) | |z0| |
| xz-plane | y = 0 (i.e., 0x + y + 0z + 0 = 0) | |y0| |
| yz-plane | x = 0 (i.e., x + 0y + 0z + 0 = 0) | |x0| |
| Plane through origin | Ax + By + Cz = 0 | |Ax0 + By0 + Cz0| / sqrt(A^2+B^2+C^2) |
| Unit-normal plane | A^2+B^2+C^2 = 1 | |Ax0 + By0 + Cz0 + D| (no division needed) |
How the formula simplifies for planes aligned with coordinate axes or passing through the origin.
Frequently asked questions
What does it mean when the distance is zero?
A distance of zero means the point lies exactly on the plane. Substituting its coordinates into Ax + By + Cz + D gives exactly zero, so the numerator is zero. This is also the condition used to check whether a given point satisfies a plane equation.
What is the difference between signed and unsigned distance?
The unsigned (absolute) distance tells you how far the point is from the plane without regard to direction. The signed distance adds that information: a positive value means the point is on the side the normal vector points toward, and a negative value means it is on the opposite side. Signed distance is used in physics and machine learning where the sign encodes which half-space the point occupies.
Does it matter which point on the plane I use in normal-vector mode?
No. Any point that lies on the plane gives the same value of D, so the final distance is the same regardless of which point you choose. The formula only uses the point to compute D = -(n . p); once D is known the reference point is no longer needed.
What happens if A, B, and C are all zero?
If A = B = C = 0, the equation 0x + 0y + 0z + D = 0 is either always true (when D = 0) or always false (when D is not zero), and does not define a proper plane. The denominator sqrt(A^2 + B^2 + C^2) becomes zero, which would cause a division by zero. The calculator returns no result in that case.
How do I find the actual foot of the perpendicular (the closest point on the plane)?
The foot F is found by moving from P along the negative normal direction by the signed distance: F = (x0 - A*t, y0 - B*t, z0 - C*t), where t = (A*x0 + B*y0 + C*z0 + D) / (A^2 + B^2 + C^2). Substituting F back into the plane equation gives exactly zero, confirming it lies on the plane.
Can I use this calculator for 2D (distance from point to line)?
Not directly. In 2D a line ax + by + c = 0 uses a similar formula: d = |a*x0 + b*y0 + c| / sqrt(a^2 + b^2). You can approximate it here by setting C = 0 and treating the result as a 2D line in the xy-plane, but the inputs are labelled for 3D usage.