Pythagorean Theorem Calculator
Find the missing side of a right triangle, with the working shown step by step.
Step-by-step solution
Triangle properties
Enter any two sides of a right triangle. The hypotenuse is the side opposite the 90° angle, so it must be longer than either leg.
Introduction | Pythagorean Theorem Calculator
Need the missing side of a right triangle quickly? Our free Pythagorean theorem calculator finds the hypotenuse or either leg in seconds. Enter any two sides and you get the answer, the step-by-step working, the area, the perimeter and both acute angles.
What Is the Pythagorean Theorem?
The Pythagorean theorem describes how the three sides of a right triangle relate to each other. A right triangle has one 90° angle. The side opposite that angle is the hypotenuse, and it is always the longest side. The other two sides are the legs.
The formula is:
a² + b² = c²
- a and b are the two legs.
- c is the hypotenuse.
In words, if you square the two legs and add them, you get the square of the hypotenuse.
How to Use the Pythagorean Theorem Calculator
- Choose what you want to find: the hypotenuse (c), leg a, or leg b.
- Enter the two known sides. Use any positive number, including decimals.
- Pick a unit and the number of decimal places if you want them.
- Click Calculate or press Enter.
Pythagorean Theorem Calculator shows the answer, the full working, and extra properties such as area, perimeter and angles. A diagram of your triangle updates as you type.
Pythagorean Theorem Formulas
| To find | Formula |
| Hypotenuse (c) | c = √(a² + b²) |
| Leg a | a = √(c² − b²) |
| Leg b | b = √(c² − a²) |
When you solve for a leg, the hypotenuse must be longer than the leg you already know. If it isn’t, no right triangle exists with those measurements.
Worked Examples
Example 1: Find the hypotenuse
A right triangle has legs of 6 cm and 8 cm.
- c² = 6² + 8²
- c² = 36 + 64 = 100
- c = √100 = 10 cm
Example 2: Find a missing leg
The hypotenuse is 13 m and one leg is 5 m.
- b² = 13² − 5²
- b² = 169 − 25 = 144
- b = √144 = 12 m
Example 3: A real-world ladder problem
A 5 m ladder leans against a wall, with its base 1.5 m from the wall. How high does it reach?
- h² = 5² − 1.5²
- h² = 25 − 2.25 = 22.75
- h = √22.75 ≈ 4.77 m
Common Pythagorean Triples
A Pythagorean triple is a set of three whole numbers that satisfy a² + b² = c². These are handy for quick mental checks:
| a | b | c |
| 3 | 4 | 5 |
| 5 | 12 | 13 |
| 8 | 15 | 17 |
| 7 | 24 | 25 |
| 20 | 21 | 29 |
| 9 | 40 | 41 |
Multiples of any triple also work. For example, 6-8-10 and 9-12-15 are both multiples of 3-4-5.
Where the Pythagorean Theorem Calculator Is Used
- Construction and carpentry: checking that corners are square using the 3-4-5 method.
- Navigation: finding the straight-line distance between two points.
- Architecture and design: calculating roof pitch, ramp lengths and stair dimensions.
- Screen sizes: working out a display’s diagonal from its width and height.
- Computer graphics and games: measuring the distance between objects.
- Everyday tasks: deciding whether a ladder, a shelf or a piece of furniture will fit.
Related Ideas
The converse of the theorem. If a triangle’s sides satisfy a² + b² = c², the triangle is a right triangle. This is how builders confirm a 90° corner.
The distance formula. The distance between two points (x₁, y₁) and (x₂, y₂) is √((x₂ − x₁)² + (y₂ − y₁)²). It is the Pythagorean theorem applied on a coordinate grid.
Three dimensions. The diagonal of a box with length l, width w and height h is √(l² + w² + h²).
Tips for Accurate Results
- Use the same unit for every side. Convert first if you mix centimetres and metres.
- Remember that the hypotenuse is always opposite the right angle and is the longest side.
- Round only at the end. Rounding earlier can introduce small errors.
- Check your answer: the hypotenuse should be longer than each leg but shorter than the two legs added together.
Final Thoughts | Pythagorean Theorem Calculator
The Pythagorean theorem is one of the most useful ideas in geometry, and this calculator saves you the arithmetic. Enter two sides, get the third, and use the step-by-step solution to check your understanding.
Bookmark this page for homework, DIY projects or any job that involves a right triangle.
Related Tools
Also visit our Payoff Website for Payoff Calculators at: All Payoff Calculators
Frequently Asked Questions | Pythagorean Theorem Calculator
What is the Pythagorean theorem in simple terms?
In a right triangle, the square of the longest side (the hypotenuse) equals the sum of the squares of the other two sides. It is written as a² + b² = c².
How do I find the hypotenuse of a right triangle?
Square both legs, add the results, then take the square root. For legs of 3 and 4, that gives 9 + 16 = 25, and √25 = 5.
How do I find a missing leg?
Square the hypotenuse, subtract the square of the known leg, then take the square root. The formula is a = √(c² − b²).
Does the Pythagorean theorem work for all triangles?
No. It works only for right triangles, which have one 90° angle. For other triangles, use the law of cosines, which includes the Pythagorean theorem as a special case.
Can the hypotenuse be shorter than a leg?
No. The hypotenuse is always the longest side of a right triangle. If your hypotenuse is not longer than a leg, the numbers are wrong or the triangle isn’t a right triangle.
What are Pythagorean triples?
They are sets of three positive whole numbers that fit a² + b² = c², such as 3-4-5, 5-12-13 and 8-15-17.
Can I use decimals or different units?
Yes. The calculator accepts decimals and lets you choose a unit. Make sure all sides use the same unit.
Who discovered the Pythagorean theorem?
It is named after the Greek mathematician Pythagoras, but the relationship was known to the Babylonians and other ancient civilizations well before his time.

