Right Triangle Calculator
A right triangle calculator is a trigonometric tool that solves for missing angles, side lengths, area, and perimeter of a right-angled triangle. By utilizing the Pythagorean theorem and basic trigonometric ratios (sine, cosine, tangent), the calculator determines all properties of the triangle when any two dimensions (with at least one side) are provided. It displays step-by-step derivations for each value, helping students learn trigonometry and assisting carpenters in measuring angular cuts.
Pick the mode that matches what you know about the right triangle. The calculator returns all three sides, both acute angles, the area, and the perimeter.
Quick Answer
Solve right triangles instantly. Enter any two known sides or one side and an angle to calculate all remaining dimensions, angles, and area.
Solve from
e.g. 3
e.g. 4
Right triangle has one 90° angle. The two non-right (acute) angles always sum to 90°. Angle a is opposite leg a; angle b is opposite leg b.
Hypotenuse & angles
5
legs 3 and 4
a² + b² = c² · Area = a × b ÷ 2 · A + B = 90°. Angles use atan, asin, acos as appropriate for the chosen mode.
Examples
Legs 3 and 4
hyp 5 · angles 36.87° / 53.13° · area 6 · perim 12
Leg 5, hypotenuse 13
other leg 12 · angles ≈ 22.62° / 67.38° · area 30
Hypotenuse 10, angle 30°
legs 5 and ≈ 8.660 · area ≈ 21.651
How it works
Formula · c = √(a² + b²); angle A = arctan(a ÷ b); area = (a × b) ÷ 2
Every right triangle satisfies a² + b² = c², where a and b are the legs and c is the hypotenuse. The acute angles satisfy A + B = 90°, and each is governed by a basic trig ratio (sin, cos, tan) against the sides.
Pythagorean · a² + b² = c²
Angles · sin A = a/c · cos A = b/c · tan A = a/b
Area & perimeter · A = a × b ÷ 2, P = a + b + c
Angle inputs and outputs are in degrees.
Learn the concept
These guides explain the geometry this tool computes, with worked examples.
What this solves, and what the neighbouring pages solve
Three pages on this site touch right triangles, and they do different jobs. Picking the wrong one is not harmful, just slower.
- This page solves the whole triangle from any two facts: two legs, a leg and the hypotenuse, or a side and one acute angle. It returns every side, both acute angles, the area and the perimeter.
- The Pythagorean theorem calculator takes sides only. Its three fields are leg a, leg b and hypotenuse c, so you cannot start from an angle there. It does report the angles once it has the sides; what it cannot do is work backwards from one.
- The triangle area calculator handles any triangle, not just right ones, and returns area alone by base and height, by three sides, or by two sides and the angle between them.
The short version: if an angle is involved, in or out, you want this page.
By hand, the 3-4-5 triangle
The smallest right triangle with whole-number sides, worked all the way through. Legs of 3 and 4.
- Hypotenuse from the theorem. c = √(3² + 4²) = √25 = 5
- The angle opposite the leg of 3. arctan(3 ÷ 4) = 36.8699°
- The other acute angle. It must complete 90 degrees, and it does: arctan(4 ÷ 3) = 53.1301°, and 36.8699 + 53.1301 = 90.
- Area is half the product of the legs, because the legs ARE the base and the height: (3 × 4) ÷ 2 = 6. Perimeter is 3 + 4 + 5 = 12.
That two-angles-sum-to-90 check is worth keeping. In any right triangle the two acute angles are complementary, so if your two answers do not add to 90 you have made an arithmetic slip somewhere.
The four ways in
- Two legs. The hypotenuse comes from the theorem and both angles from arctan.
- A leg and the hypotenuse. The missing leg is √(c² − a²). A hypotenuse of 5 with a leg of 3 gives the other leg as 4.
- A leg and its opposite angle. The other leg is the leg divided by the tangent, and the hypotenuse is the leg divided by the sine.
- The hypotenuse and an angle. Sides come straight from sine and cosine. A hypotenuse of 10 at 30 degrees gives legs of 5 and 8.660254.
Edge cases, and what the calculator refuses
- A hypotenuse no longer than a leg. Rejected, because no such triangle exists. The hypotenuse is opposite the right angle, which is the largest angle, so it is always the longest side.
- An angle of 0 or 90 degrees. Rejected. At 90 the triangle would have two right angles; at 0 it collapses to a line. Both are outside the range the trigonometry is meaningful over.
- Zero or negative sides. Rejected. A length of zero is not a shortcut to a degenerate answer, it is an input error.
- Non-right triangles. Everything here assumes one angle is exactly 90 degrees. For any other triangle the law of sines and the law of cosines replace these relationships entirely.
Where these results come from
Nowhere that could be cited, in the sense a source line usually means. The Pythagorean theorem and the definitions of sine, cosine and tangent are results, not measured values: they follow from the definitions of a right triangle and the unit circle. No outside standard publishes a number this page could reference, so it references none rather than decorating an identity with a citation it does not need.
What can be checked is the arithmetic, and it is. The figures quoted above are recomputed from the calculator's own formulas by an automated test, so changing the code fails the page rather than quietly leaving the prose wrong.
Your figures stay in the page
The sides and angles you enter are processed by this page in your browser. They are not sent to a server, not stored after you close the tab, and not visible to anyone else. There is no account and nothing to sign up for.
Isosceles right triangles, the 45-45-90 case
An isosceles right triangle is one whose two legs are the same length, which forces both acute angles to 45 degrees. There is no separate mode for it because none is needed: enter the same value for both legs in the two-legs mode and the solver returns 45 and 45 along with the hypotenuse, which comes out as the leg times the square root of 2.
Related geometry calculators
- Pythagorean theorem calculator when you only need to find one missing side from the other two.
- Triangle area calculator for any triangle, including base-and-height, Heron, and SAS.
- Square root calculator for the radical step in the Pythagorean formula.
- Area calculator for area across multiple 2D shapes.
- Perimeter calculator for perimeter across common shapes.
- All education calculators.
Related Calculators
More tools from Education



