Try it with your numbers
Show every step
The solver above shows each step for any two sides you enter. The rest of this page explains why the formula is true, which traps cost the most points, and the shortcuts that make most problems quick.
What Does the Pythagorean Theorem Say?
The theorem is really a statement about area. Build a square on each side of a right triangle, and the area of the big square on the hypotenuse equals the two smaller squares added together. A square with side has area (see the area of a square), so the equation is just that area statement written with side lengths.
Only right triangles qualify, which is one specific entry among the types of triangles. The other two angles in a right triangle are acute and complementary, meaning they add to . That fact is quietly responsible for the whole theorem, as the next section shows.
The letters are positions, not fixed names. The hypotenuse is whichever side faces the angle, and the legs are the two sides that form it. You can call the legs and in either order, but must be the hypotenuse. If a diagram labels the hypotenuse , then stands alone on one side of the equation, and the two leg squares go on the other.
Quick check
Answer:
Why Does the Pythagorean Theorem Work? One Clean Proof

Take four identical right triangles with legs and and hypotenuse . Arrange them inside a large square of side , each triangle pointing inward from a corner, so that a tilted square of side is left in the middle.
The tilted middle shape is a square only because the two acute angles of each triangle add to . Change the angle and the proof stops working.
Now count the area of the big square two ways. From the outside it is . From the inside it is the tilted square plus four triangles, each with area :
The terms cancel, and the theorem is left standing. Nothing was assumed about the specific lengths, so it holds for every right triangle.
Hundreds of other proofs exist, and a collection of them lives on the page about the proofs of the Pythagorean theorem. One of the most elegant uses similar triangles: drop a line from the right angle straight to the hypotenuse, and it cuts the triangle into two smaller copies of the original. Matching their ratios gives the same equation with no pictures of squares at all.
How to Find the Hypotenuse With the Pythagorean Theorem
When both legs are known, the hypotenuse is the easy case. The process has four moves:
- Confirm there is a right angle and mark the side opposite it as .
- Square both legs and add them.
- Take the positive square root of the sum.
- Simplify the radical, then sanity-check the size.
Example 1. A right triangle has legs and . Find the hypotenuse.
The sanity check is quick. The hypotenuse must beat the longer leg () but stay below the sum of the legs (), a limit that comes from the triangle inequality theorem. Also, and , so should land between and , nearer to . A result of passes both tests.
The costliest slip here is writing or . Adding the legs first gives in this example, far too large. The squares are added, never the sides. Another common slip is stopping at and forgetting the final root.
How to Find a Missing Leg (and Skip the Subtraction)
When the hypotenuse is known, rearrange the equation to . The sign flips because the hypotenuse is the biggest term, so it comes first and the known leg is subtracted. If you ever find yourself adding two numbers to get a leg, stop and recheck which side is .
Example 2. The hypotenuse is and one leg is . Find the other leg.
Rather than computing and subtracting , factor the difference of squares:
Check by going forward: . The factored form keeps the numbers small, which helps most when the hypotenuse is large. The result is one of the whole-number Pythagorean triples.
Try this: Find the missing leg when the hypotenuse is and one leg is , using without ever computing . Then check by squaring all three sides.
A built-in alarm helps too. If the leg you are given is longer than the hypotenuse, or the number under the root comes out negative, the sides are mislabeled or the triangle cannot exist.
Is It a Right Triangle? The Converse, Acute and Obtuse Cases

The theorem works backward as well. If three side lengths satisfy , with the longest, the triangle must have a right angle. This is how carpenters and surveyors test a corner using only a tape measure.
The converse extends to a three-way test. Compare with :
- If , the triangle is right.
- If , the triangle is acute (every angle under ).
- If , the triangle is obtuse (one angle over ).
Only the longest side needs testing. The angles of a triangle add to (the triangle angle sum theorem), so at most one angle can reach or more, and it always sits opposite the longest side.
Example 3. Classify a triangle with sides , and .
First confirm it exists: . Then compare:
Since , the longest side is longer than a right triangle would allow, so the opposite angle has been pushed past . The triangle is obtuse. This works because the general law of cosines is , and the term turns positive when is obtuse.
Quick check
Answer:
Pythagorean Theorem in Coordinates and 3D: Distance Formulas
The distance formula is the theorem in disguise. To find the distance between and , treat the horizontal change and vertical change as the legs of a right triangle:
For and , the legs are and , so . Squaring removes negative differences, so the order of the points never matters.
A point is on a circle with center and radius when its distance to the center is . That gives .
That card is the whole idea behind the equation of a circle. The same thinking extends to three dimensions by applying the theorem twice. For a box with length , width and height , the floor diagonal is , and the space diagonal then forms a right triangle with the height:
For a box, the floor diagonal is , and . This tells you the longest rod that fits inside a shipping crate.
Pythagorean Triples and Special Triangles as Shortcuts
Spotting a familiar triple turns a calculation into recognition. Any multiple of a triple is also a triple, so and come from .
| Primitive triple | Check |
|---|---|
Two angle-based shapes also come up constantly. In a 45-45-90 triangle the legs are equal, so and the hypotenuse
Quick check
Answer:
Practice problems
0 of 5 solved
- A right triangle has legs and . Find the hypotenuse.
Answer:
Add the squares of the legs: . Take the positive root: . - A right triangle has hypotenuse and one leg . Find the other leg.
Answer:
Subtract, because the hypotenuse is known: . Then . - A right triangle has legs and . Find the hypotenuse to two decimal places.
Answer:
. So . Since and , the value sits just above : . - A triangle has sides , and . Is it acute, right or obtuse?
Answer:
The longest side is , and , so the triangle exists. Compare with . Since , the largest angle is greater than , so the triangle is obtuse. - The legs of a right triangle are and , and the hypotenuse is . Find .
Answer:
Write , which expands to . Simplify to , which factors as . A length cannot be negative, so (the legs are and ).
Common questions
What is the Pythagorean theorem in simple terms?
In any right triangle, if you square the two shorter sides (the legs) and add the results, you get the square of the longest side (the hypotenuse). In symbols, . It lets you find a missing side whenever the other two are known.
Can the Pythagorean theorem be used on any triangle?
No. The equation holds only when one angle is exactly . For other triangles, the law of cosines gives , which reduces to the Pythagorean theorem when .
How do you know which side is the hypotenuse?
The hypotenuse is the side directly opposite the right angle, and it is always the longest side. It is the only side that never touches... no: it is the one side that does not form the right angle. Label it and the equation sorts itself out.
What is the converse of the Pythagorean theorem?
If the three sides of a triangle satisfy , with the longest side, then the triangle has a right angle. If the triangle is acute, and if $a^2 + b^2 < c^2$ it is obtuse.
Who discovered the Pythagorean theorem?
Greek tradition credits Pythagoras (around 500 BCE), but Babylonian clay tablets from roughly 1800 BCE already list whole-number triples that fit the rule. Ancient Chinese and Indian texts also describe it, so the name reflects who proved it in Greek mathematics, not who first noticed it.
Does the Pythagorean theorem work with decimals and fractions?
Yes. Side lengths can be any positive real numbers, so decimals, fractions and radicals all work. Only the final square root needs care: take the positive root, because a length cannot be negative.