Pythagorean Theorem Calculator

Find the hypotenuse or a missing leg of a right triangle with a² + b² = c², plus both acute angles, the area and the perimeter.

Loading the calculator…

a² + b² = c²

In any right triangle, the square of the hypotenuse (the side opposite the right angle) equals the sum of the squares of the two legs. Know two sides and you can find the third.

Two ways to rearrange it

  • Missing hypotenuse: c = √(a² + b²)
  • Missing leg: b = √(c² − a²). The hypotenuse must be the longest side, or there is no triangle.

Practical example: is the corner square?

Builders check right angles with the 3-4-5 rule. Measure 3 units along one wall and 4 along the other: if the diagonal between the two marks is exactly 5, the corner is 90°. On a larger deck, 6-8-10 or 9-12-15 works the same way.

Example: ladder against a wall

A 5 m ladder stands 1.5 m from the wall. How high does it reach? b = √(5² − 1.5²) = √(25 − 2.25) = √22.75 ≈ 4.77 m.

Common Pythagorean triples

a b c
3 4 5
5 12 13
8 15 17
7 24 25

The angles come from trigonometry: the angle opposite side a is arctan(a ÷ b). For lines on a graph, the slope calculator gives the distance between two points with the same theorem.

FAQ

Does it work for any triangle?

No, only right triangles. For other triangles, use the law of cosines.

Which side is the hypotenuse?

The side opposite the 90° angle. It is always the longest side.

Do the units matter?

Use the same unit for every side. The answer comes out in that unit.

Last reviewed November 30, 2026. Results are estimates for general information.