Pythagorean Theorem Calculator
Enter any two sides of a right triangle to find the third.
Runs in your browser — nothing is sent or saved.
How to use the Pythagorean theorem calculator
- Enter any two of the three sides.
- Leave the side you want to find blank.
- Read the missing side and the formula.
- Copy the link to save or share it.
The Pythagorean theorem
The Pythagorean theorem relates the three sides of a right-angled triangle: a squared plus b squared equals c squared, where a and b are the two shorter sides, called the legs, and c is the hypotenuse, the longest side opposite the right angle. So if you know any two sides, you can find the third. This is one of the most used results in geometry, from construction to navigation, and it comes from Pythagoras. As a hypotenuse calculator it also finds any right triangle side you are missing.
Finding the hypotenuse or a leg
To find the hypotenuse, add the squares of the two legs and take the square root: c equals the square root of a squared plus b squared. To find a leg, subtract instead: a equals the square root of c squared minus b squared. That subtraction only works when the hypotenuse is longer than the known leg, so the tool flags the impossible case where it is not, since no real right triangle exists there.
A worked example
The classic 3-4-5 triangle shows it clearly. With legs of 3 and 4, the hypotenuse is the square root of 3 squared plus 4 squared, which is the square root of 9 plus 16, the square root of 25, which is 5. Enter 3 and 4 and leave the hypotenuse blank to see it.
FAQ
How do I find the hypotenuse?
Add the squares of the two legs and take the square root. Enter the two legs, leave the hypotenuse blank, and the tool returns c equals the square root of a squared plus b squared.
How do I find a missing leg?
Subtract the known leg's square from the hypotenuse's square, then take the square root. Enter the hypotenuse and one leg and leave the other blank.
Does this work for any triangle?
No. The Pythagorean theorem holds only for right-angled triangles. For other triangles, use the triangle calculator, which applies the law of cosines.
Why does it say no real result?
Because you entered a leg that is not shorter than the hypotenuse. In a right triangle the hypotenuse is always the longest side, so such lengths cannot form one.
Is my information private?
Yes. Everything is calculated in your browser and nothing you enter is uploaded or saved.