AnsRioSmart tools. Clear answers.
Home / Math & statistics / Distance from a point to a line
Math & statistics

Distance from a point to a line

Distance from a point to a line: For line ax + by + c = 0, perpendicular distance is |ax₀ + by₀ + c| / √(a² + b²).

Make it your own ⌁ Runs on your device

Your inputs are processed locally and are not added to analytics or saved history.

YOUR RESULT
Ready when you are.

Enter your values, then select Calculate.

How it works

For line ax + by + c = 0, perpendicular distance is |ax₀ + by₀ + c| / √(a² + b²).

Input definitions

Line coefficient a
Enter the value in the labeled unit.
Line coefficient b
Enter the value in the labeled unit.
Line coefficient c
Enter the value in the labeled unit.
Point x
Enter the value in the labeled unit.
Point y
Enter the value in the labeled unit.

A worked example

Line coefficient a
3
Line coefficient b
4
Line coefficient c
0
Point x
0
Point y
5
4

Assumptions & limits

Uses the units and scope stated in the input labels. Results are rounded for display; verify the model is appropriate for your situation.

Sources & review

Maintained by AnsRio. Methods and examples use automated checks; this does not imply independent professional certification.

Method updated 2026-10-18. Content checked against the stated method and examples. Our verification approach.

Common questions

Can a vertical line be used?

Yes. Use b = 0 and a nonzero coefficient a. Both coefficients cannot be zero because that does not define a line.

How does Distance from a point to a line work?

For line ax + by + c = 0, perpendicular distance is |ax₀ + by₀ + c| / √(a² + b²).

What should I check before using Distance from a point to a line?

Uses the units and scope stated in the input labels. Results are rounded for display; verify the model is appropriate for your situation.

↗
Made for the question in front of you.

No sign-up. Tool inputs stay on your device.

How we work