Pythagorean Theorem Calculator
Enter two sides of a right-angled triangle and this calculator finds the third using Pythagoras’ theorem, showing the full working plus the triangle’s area and perimeter.
Outside the supported range
The longest side, opposite the right angle
Formula: c = √(a² + b²)
| Step | Value |
|---|---|
| Pythagoras’ theorem | a² + b² = c² |
| Known side a | 3 |
| Known side b | 4 |
| Substitute the values | 3² + 4² = c² |
| Square each side | 9 + 16 = c² |
| Add the squares | 25 = c² |
| Square root | c = √25 |
| Hypotenuse | c = 5 |
How to use this calculator
- Choose what to find — Hypotenuse when you know both shorter sides, or Shorter side when you know the hypotenuse and one shorter side. Only the two inputs that mode needs are shown.
- Enter the two known lengths, using the same unit for both.
- Read the result: the missing side is the large figure, with the triangle’s area and perimeter beside it and the full working in the calculation table.
Pythagoras’ theorem applies only to right-angled triangles, and the hypotenuse must always be the longest side. The calculation runs in the page as you type — nothing is sent to a server.
How Pythagoras’ theorem is calculated
In a right-angled triangle, the square of the hypotenuse equals the sum of the squares of the other two sides.
- a and b — the two shorter sides, called the legs (interchangeable)
- c — the hypotenuse, the longest side, opposite the right angle
The same relationship rearranges to solve for whichever side is missing:
- Find a shorter side: a = √(c² − b²)
- Area of the triangle: (a × b) ÷ 2
- Perimeter of the triangle: a + b + c
Results are shown to at most six decimal places with trailing zeroes removed, so an exact answer reads 5 and an irrational one reads 1.414214. No intermediate value is rounded before the final figure is formatted.
Worked example: finding the hypotenuse
A right-angled triangle has shorter sides of 3 and 4. The hypotenuse is:
| Step | Value |
|---|---|
| Pythagoras’ theorem | a² + b² = c² |
| Known side a | 3 |
| Known side b | 4 |
| Substitute the values | 3² + 4² = c² |
| Square each side | 9 + 16 = c² |
| Add the squares | 25 = c² |
| Square root | c = √25 |
| Hypotenuse | c = 5 |
The area is (3 × 4) ÷ 2 = 6 square units and the perimeter is 3 + 4 + 5 = 12 units.
Worked example: finding a shorter side
A right-angled triangle has a hypotenuse of 10 and one shorter side of 6. The missing shorter side is:
| Step | Value |
|---|---|
| Pythagoras’ theorem | a² + b² = c² |
| Known hypotenuse | c = 10 |
| Known shorter side | b = 6 |
| Rearrange the formula | a² = c² − b² |
| Substitute the values | a² = 10² − 6² |
| Square each side | a² = 100 − 36 |
| Subtract the squares | a² = 64 |
| Square root | a = √64 |
| Missing shorter side | a = 8 |
Common right-angled triangles
A Pythagorean triple is three whole numbers that satisfy a² + b² = c² exactly. Most right-angled triangles do not have whole-number sides.
| Side a | Side b | Hypotenuse c |
|---|---|---|
| 3 | 4 | 5 |
| 5 | 12 | 13 |
| 8 | 15 | 17 |
| 7 | 24 | 25 |
| 1 | 1 | ≈ 1.414214 |
When Pythagoras’ theorem applies
Pythagoras’ theorem works only for right-angled triangles — those with one 90° angle. The hypotenuse is always the longest side and always sits opposite the right angle. For a triangle with no right angle, use the law of cosines instead. This calculator does not check angles, so enter lengths you know belong to a right-angled triangle.