Hypotenuse Calculator - Pythagorean Theorem Tool
Calculate the hypotenuse of a right triangle using the Pythagorean theorem. Enter any two known values to solve for side A, side B, or the hypotenuse length.
Hypotenuse Calculator
Documentation
Hypotenuse Calculator
A hypotenuse calculator finds the length of the longest side of a right triangle, called the hypotenuse. It uses the Pythagorean theorem, a rule that connects the three sides of any right triangle.
What Is the Hypotenuse?
A right triangle has one 90-degree angle, formed where two sides meet at a square corner. Those two sides are called legs. The third side, opposite the right angle, is the hypotenuse. It is always the longest side of the triangle.
Pythagorean Theorem Formula
The Pythagorean theorem states that the square of the hypotenuse equals the sum of the squares of the two legs.
- c is the hypotenuse
- a and b are the two legs
To find a missing leg instead of the hypotenuse, the formula can be rearranged:
The theorem is named after the Greek mathematician Pythagoras, who lived around 570 to 495 BCE. The relationship was known earlier than that. Babylonian clay tablets dated to about 1800 BCE show that Babylonian mathematicians already used it, more than a thousand years before Pythagoras.
How to Calculate the Hypotenuse
To find the hypotenuse by hand, follow four steps.
- Square the length of side A (multiply it by itself).
- Square the length of side B.
- Add the two squared values together.
- Take the square root of that sum.
The calculator on this page performs the same four steps. Choose "Find Hypotenuse," "Find Side A," or "Find Side B" from the menu, then enter the two known lengths. The result updates as soon as valid numbers are entered, rounded to two decimal places.
Both sides must use the same unit of measurement, such as inches or meters. The calculator does not convert between units, so a value entered in feet and a value entered in inches will not produce a meaningful result together.
Example Calculation
A right triangle has a side A of 3 feet and a side B of 4 feet.
c = √(3² + 4²) = √(9 + 16) = √25 = 5.00 feet
This 3-4-5 pattern is a shortcut carpenters use to check that a corner is square. Measure 3 feet along one edge and 4 feet along the perpendicular edge. The diagonal distance between those two points should measure exactly 5 feet. Any multiple of the pattern works the same way, such as 6-8-10 or 30-40-50.
A second example uses decimal values. A right triangle has a side A of 2.5 inches and a side B of 6.8 inches.
c = √(2.5² + 6.8²) = √(6.25 + 46.24) = √52.49 ≈ 7.24 inches
Television and monitor sizes are measured this way. The stated screen size is the diagonal, which is the hypotenuse of the rectangle formed by the screen's width and height.
Finding a Missing Side
If the hypotenuse and one leg are already known, the calculator can find the other leg. Select "Find Side A" or "Find Side B," then enter the hypotenuse and the known leg.
For example, a right triangle has a hypotenuse of 10 meters and a side B of 6 meters.
a = √(10² − 6²) = √(100 − 36) = √64 = 8.00 meters
The hypotenuse must always be longer than either leg, since it is the longest side of the triangle. If a value entered for the hypotenuse is not greater than the known leg, the calculator shows an error instead of a result, because no such right triangle exists.
Common Uses
The Pythagorean theorem is used whenever a straight diagonal distance needs to be found from two perpendicular measurements.
- Construction and carpentry: checking that a frame or wall corner is square, and calculating rafter or stair stringer lengths.
- Surveying: converting horizontal and vertical distances into a direct line-of-sight distance.
- Navigation and computer graphics: the distance formula for two points on a graph, d = √[(x₂−x₁)² + (y₂−y₁)²], is the same theorem applied to coordinates.
- Education: it is one of the first geometric proofs most students encounter, and can be checked with simple whole-number examples like 3-4-5 or 5-12-13.
The theorem applies only to right triangles. For a triangle without a 90-degree angle, the law of cosines is used instead.
Frequently Asked Questions
What is the formula for the hypotenuse? c = √(a² + b²), where a and b are the two legs of a right triangle and c is the hypotenuse.
Can this be used for triangles without a right angle? No. The Pythagorean theorem applies only to right triangles. A triangle without a 90-degree angle requires the law of cosines instead.
What is the 3-4-5 rule? It is a shortcut for checking a square corner. If one side measures 3 units, an adjacent perpendicular side measures 4 units, and the diagonal between their endpoints measures 5 units, the corner is a right angle. Any multiple of 3-4-5, such as 6-8-10 or 30-40-50, works the same way.
Do both sides need to use the same unit of measurement? Yes. Both legs must be entered in the same unit, such as both in feet or both in meters. Mixing units, like feet and inches, produces a result that is mathematically correct but physically meaningless.
Why does the calculator show an error for some hypotenuse and side combinations? The hypotenuse is always the longest side of a right triangle. If the value entered for the hypotenuse is not greater than the known leg, no valid right triangle exists, so the calculator returns an error instead of a result.
How many decimal places does the result show? Two. The calculator keeps full precision internally during the calculation and rounds only the displayed number.
Is this the same as the distance formula? Yes. The distance formula in coordinate geometry, d = √[(x₂−x₁)² + (y₂−y₁)²], is the Pythagorean theorem applied to two points on a graph. The horizontal and vertical gaps between the points form the two legs of a right triangle.