Pythagorean Theorem Calculator
Calculate missing side of right triangle using a²+b²=c²
Pythagorean Theorem Calculator tool
Results
c = —
Formula:
Triangle Visualization:
│\
│ \
4 │ \ c
│ \
└────┘
3
Step-by-step:
- 1.a = 3, b = 4
- 2.a² = 3² = 9
- 3.b² = 4² = 16
- 4.a² + b² = 9 + 16 = 25
- 5.c = √25 = 0
Pythagorean Theorem Calculator: key facts
- What it does
- Calculate missing side of right triangle using a²+b²=c²
- Category
- Math Calculators
- Cost
- Free, with no account, sign-up, or install.
- Your data
- Runs entirely in your browser — the files and text you enter are never uploaded to a server.
- Last reviewed
- . Report an incorrect result.
What the Pythagorean Theorem Calculator does
The Pythagorean theorem — a² + b² = c² — relates the three sides of a right triangle, and this calculator solves for whichever side you are missing. Tell it which side to find, enter the other two, and it returns the answer with the algebra and a triangle diagram.
Students lean on it throughout geometry and trigonometry; in practice, carpenters, builders, and DIYers use it to check that corners are square and to find diagonal lengths. Because it solves for any side — not just the hypotenuse — it handles the full range of right-triangle problems, and the visual diagram makes clear which side is which.
Using the Pythagorean Theorem Calculator, step by step
- Choose which side to solve for: side a, side b, or the hypotenuse c.
- Enter the two sides you know.
- Read the calculated length of the missing side.
- Review the formula derivation and the triangle diagram that highlights the side you solved for.
Solving for any of the three sides
The theorem states that the square on the hypotenuse equals the sum of the squares on the other two sides, and the tool rearranges it depending on which side you leave blank. Finding the hypotenuse adds the two squares and takes the root; finding a leg subtracts the known leg's square from the hypotenuse's before rooting.
The hypotenuse is always the longest side and always opposite the right angle, and that ordering is what makes the rearrangement valid — subtracting a larger square from a smaller one would leave a negative under the root, which signals that the values could not form a right triangle at all.
The theorem applies only to right-angled triangles. For any other triangle the corresponding relationship is the law of cosines, which reduces to Pythagoras exactly when the angle is ninety degrees.
- The defaults — legs of 3 and 4 — give a hypotenuse of exactly 5, the best-known Pythagorean triple.
- Legs of 1 and 1 give √2, about 1.4142 — an irrational result from the simplest possible inputs.
- Working backwards: a hypotenuse of 13 with one leg of 5 gives the other as 12.
What makes this one worth using
- It solves for any of the three sides, not just the hypotenuse, covering every right-triangle case.
- It includes a triangle diagram that updates to show which side you are finding, anchoring the algebra visually.
- It shows the full derivation, from squaring the known sides to the final square root.
- It runs entirely in your browser, free and private.
Triples, and squaring up a real corner
Whole-number solutions are called Pythagorean triples, and 3-4-5 is the smallest. Any multiple of a triple is also a triple, so 6-8-10 and 9-12-15 work equally well — a fact builders and carpenters use directly. Measuring three units along one edge and four along another, then adjusting until the diagonal reads exactly five, produces a genuine right angle without any instrument. Larger multiples give better accuracy over longer runs.
The theorem extends naturally beyond two dimensions. The diagonal of a rectangular box is the square root of the sum of three squares, which is the same idea with one more term, and the distance formula in coordinate geometry is Pythagoras applied to coordinate differences.
Two notes for practical use. Screen and display sizes are quoted as the diagonal, so recovering width and height needs the aspect ratio as well. And the converse holds: if three lengths satisfy the equation then the triangle they form must be right-angled, which is what makes the builder's check valid in the first place.
Frequently Asked Questions
What is the Pythagorean theorem?
For a right triangle, the square of the hypotenuse (the longest side, opposite the right angle) equals the sum of the squares of the other two sides: a² + b² = c². It only applies to right triangles.
How do I find a leg instead of the hypotenuse?
Rearrange the formula: a = √(c² − b²). Choose to solve for side a or b, enter the hypotenuse and the other leg, and the calculator subtracts and takes the square root for you.
How is this used to check a square corner?
Builders use the 3-4-5 rule: if a corner's two sides measure 3 and 4 units, the diagonal should be exactly 5 for a true right angle. You can verify any such measurement by solving for the hypotenuse here.
Does the theorem work for any triangle?
No — it applies only to right triangles, those with a 90-degree angle. For triangles without a right angle you need the law of cosines or law of sines instead. This calculator assumes a right triangle in every mode.