Right triangle calculator
A right triangle calculator finds every missing side and angle of a right-angled triangle from any two values, as long as one of them is a side. It uses the Pythagorean theorem for the sides and SOH CAH TOA for the angles. In our Trigonometry Calculator, press Right angle at C, type the two values you know and press Solve: it gives all three sides, both acute angles, the area and the perimeter.
The calculator solves any triangle, so the right angle is just one of the three values it needs. It redraws your triangle to scale, so you can see the shape as well as the numbers.
Trigonometry Calculator
Interactive triangle solver with step-by-step
How to use the right triangle calculator
- Open the calculator. It starts on the unit circle, so at the top of the sidebar choose Standard triangle.
- Under Triangle, find the panel that says "Type any three values, including a side, then Solve". It has boxes for the sides a, b and c and the angles A, B and C.
- Press Right angle at C. It puts 90° in the C box, which makes c the hypotenuse, the long side opposite the right angle. The legs are a and b.
- Type the two values you know. Side a is opposite angle A, and side b is opposite angle B.
- Press Solve. The triangle is redrawn, and Measurements lists every side and angle, the area and the perimeter.
A line under the buttons names the method it used, such as "Two sides and the angle between them (SAS)". The Formulas section adds Pythagoras and SOH CAH TOA cards with your triangle's numbers in. The calculator gives the results but does not write out the working for a solve, so the examples below show it. Angles are in degrees unless you turn off Degrees under Display. Clear empties the boxes for the next triangle.
Which two values can you use?
With the right angle filled in, any two more values work, as long as at least one is a side. Two angles alone fix the shape but not the size, and the calculator says so.
| You know | Type in | Method line in the calculator |
|---|---|---|
| Both legs | a and b | Two sides and the angle between them (SAS) |
| A leg and the hypotenuse | a and c | Two sides and an angle not between them (SSA) |
| The hypotenuse and an angle | c and A | Two angles and a side (AAS) |
| A leg and the angle next to it | b and A | Two angles and the side between them (ASA) |
| A leg and the angle opposite it | a and A | Two angles and a side (AAS) |
Right triangle formulas
Every right triangle calculator uses the same handful of rules. Label the right angle C, the hypotenuse c and the legs a and b, with each side opposite the angle of the same letter.
| To find | Formula |
|---|---|
| The hypotenuse | c = √(a² + b²) |
| A leg | a = √(c² − b²) |
| Angle A from two sides | sin A = a/c, cos A = b/c, tan A = a/b |
| A side from an angle | a = c sin A, b = c cos A, a = b tan A |
| The other acute angle | B = 90° − A |
| Area | Area = ½ab, half the product of the legs |
| Perimeter | a + b + c |
| Height to the hypotenuse | h = ab/c (not shown by the calculator) |
The first two rows are the Pythagorean theorem, which our Pythagorean theorem calculator guide covers in depth, along with the hypotenuse calculator guide. The angle rows are SOH CAH TOA, explained in our SOHCAHTOA calculator guide: sine is opposite over hypotenuse, cosine is adjacent over hypotenuse, and tangent is opposite over adjacent.
Worked examples you can check in the calculator
Example 1: two legs
A right triangle has legs of 2.5 cm and 6 cm. Find the hypotenuse, both angles, the area and the perimeter.
Then B = 90° − 22.62° = 67.38°. The area is ½ × 2.5 × 6 = 7.5 cm² and the perimeter is 2.5 + 6 + 6.5 = 15 cm. In the calculator: Right angle at C, a = 2.5, b = 6, Solve. Measurements shows the same five values.
Example 2: a leg and the hypotenuse
The hypotenuse is 15 and one leg is 9. Find the other leg and the angles.
So B = 53.13°. Type a = 9 and c = 15 with the right angle at C. If you type a hypotenuse shorter than the leg, the calculator tells you that no triangle fits, because the hypotenuse is always the longest side.
Example 3: the hypotenuse and an angle
The hypotenuse is 10 and angle A is 35°. Side a is opposite A, so it uses sine, and side b is next to A, so it uses cosine:
The third angle is B = 90° − 35° = 55°. In the calculator, type c = 10 and A = 35 with the right angle at C.
Example 4: a leg and an angle, the height of a tree
A tree casts a shadow 6 m long when the sun is 40° above the ground. How tall is the tree? The shadow is the leg next to the 40° angle and the tree is the leg opposite it, so use tangent:
The tree is about 5.03 m tall, and the line from the top of the tree to the end of the shadow is 6 ÷ cos 40° = 7.83 m. In the calculator, put the 40° at A, so the shadow is b = 6 and the tree is a. Solve gives a = 5.03 and c = 7.83.
Now try one in the course, then press Mark to check it:
Find the missing side practice.
Press Mark to have your answer marked in the Trigonometry course.
Right triangle angle calculator: finding the angles
To find an angle, you need two sides. Choose the ratio that uses the two sides you have, then use the inverse function, written sin⁻¹, cos⁻¹ or tan⁻¹ (arcsin, arccos and arctan in the US). The two acute angles always add up to 90°, so once you have one, the other is 90° minus it.
For a quick angle without solving the whole triangle, use the calculator's Evaluate box. With Degrees on, inverse functions give degrees, so typing atan(2.5/6) gives 22.619865, the angle from Example 1. Typing asin(9/15) gives 36.869898, the angle from Example 2.
Special right triangle calculator: 45-45-90 and 30-60-90
Two right triangles have sides in fixed ratios, so you can find every side from one of them without trigonometry.
| Triangle | Angles | Sides in the ratio | Example |
|---|---|---|---|
| Isosceles right | 45°, 45°, 90° | 1 : 1 : √2 | Legs 4 and 4, hypotenuse 4√2 ≈ 5.66 |
| Half an equilateral | 30°, 60°, 90° | 1 : √3 : 2 | Short leg 5, long leg 5√3 ≈ 8.66, hypotenuse 10 |
In the 30-60-90 triangle, the hypotenuse is always twice the shortest side, and the shortest side is opposite the 30° angle. To check the example, type a = 5 and A = 30 with the right angle at C: the calculator gives b = 8.66 and c = 10. Type a = 4 and b = 4 and the triangle is labelled isosceles right, with c = 5.66.
Area and perimeter of a right triangle
The two legs of a right triangle are a base and its height, so the area is half their product. For legs of 7 and 24, the area is ½ × 7 × 24 = 84 and the hypotenuse is 25, so the perimeter is 7 + 24 + 25 = 56. Measurements gives both after a solve. If you only know the hypotenuse and an angle, find the legs first, as in Example 3, then halve their product: ½ × 5.74 × 8.19 = 23.5.
Common mistakes
- Putting the hypotenuse in the wrong place. It is always opposite the right angle and always the longest side. With the right angle at C, it is c.
- Mixing up opposite and adjacent. They depend on which angle you are using. The side opposite A is next to B.
- A calculator in radians. sin 35 in radians is about −0.43, not 0.57. Check your calculator shows DEG.
- Solving with only angles. Two angles tell you the shape but not the size. You need at least one length.
- Forgetting the angles add to 90°. The two acute angles of a right triangle always sum to 90°, which is a quick check on your answers.
- Rounding too early. Keep full values until the end, especially when one answer feeds into the next.
Practise right triangles in a short timed paper
Right triangle trigonometry comes up in Geometry, Algebra 2 & SAT Math practice, and in GCSE Maths Higher in the UK. Each daily paper is a short timed paper of 8 questions worth 25 to 35 marks, and the papers mix topics. The Trigonometry course starts with the sides of a right triangle and works up to the sine and cosine rules for any triangle.
Common questions
How do you solve a right triangle?
How do you find the angles of a right triangle?
Can you solve a right triangle with only the angles?
Is the hypotenuse always the longest side?
How do you find the area of a right triangle?
What is a 30 60 90 triangle?
Revision cards
Say the answer first, then flip the card to check it.
Where to go next
- Solve it
Trigonometry Calculator
Interactive triangle solver with step-by-step
Open the tool - Learn it
Trigonometry
Understand the true math behind everyday geometry with trig functions and identities
Start the course - Test it
Geometry, Algebra 2 & SAT Math
A new exam-style paper every day, with instant marking and a mark scheme
Start today's paper