Right Triangle Calculator With Steps

Use this right triangle calculator to solve any right-angled triangle from two known values. Enter two sides, one side and an acute angle, or the area and perimeter, and the calculator finds the missing sides, the hypotenuse, both acute angles, the area, the perimeter and the altitude. It also draws a live diagram and shows every step.

How to Use the Right Triangle Calculator

  1. Enter any two known values. Use two sides, one side and one acute angle, or the area and the perimeter. Two angles alone are not enough, because they fix the shape but not the size.
  2. Set the angle position. If you enter an angle θ, choose whether it is the base angle (α) or the top angle (β). Opposite and adjacent sides are always measured from the angle you choose.
  3. Choose degrees or radians. In radians mode you can type expressions such as pi/3 or pi/4.
  4. Press Calculate. The calculator fills in the missing values, labels the live diagram and shows the formulas step by step. Use the rounding menu to pick 2 to 6 decimal places.

Use the same length unit for every side (all cm, or all inches). Area is given in square units; sides, perimeter and altitude are in the same linear unit you entered.

In this calculator, a is the vertical leg (height), b is the horizontal leg (base) and c is the hypotenuse.

What Is a Right Triangle?

A right triangle (or right-angled triangle) has one angle of exactly 90°. The side opposite the right angle is the hypotenuse. It is always the longest side. The other two sides are the legs. Because the angles of a triangle add up to 180°, the two other angles always add up to 90°.

Right triangle diagram labeled with legs a and b, hypotenuse c, angles alpha and beta, and a² + b² = c²

Pythagorean Theorem

In every right triangle, the square of the hypotenuse equals the sum of the squares of the legs:

a² + b² = c²

This is the formula the calculator uses whenever two sides are known. It only works for right triangles.

How to Find the Hypotenuse

When you know both legs, use this page as a hypotenuse calculator. Enter a and b, and it returns c:

c = √(a² + b²)

Example: legs a = 6 and b = 8
c = √(6² + 8²) = √(36 + 64) = √100 = 10

Another example: a = 8 and b = 15 gives c = √(64 + 225) = √289 = 17.

How to Find a Missing Side

When you know the hypotenuse and one leg, rearrange the theorem:

a = √(c² − b²) or b = √(c² − a²)

Example: c = 13 and b = 5
a = √(13² − 5²) = √(169 − 25) = √144 = 12

The hypotenuse must be longer than the known leg. If c is less than or equal to the leg, the values cannot form a right triangle and the calculator will show an error.

How to Find Angles in a Right Triangle

The trigonometric ratios link each acute angle to the sides. Measured from an angle θ:

  • sin θ = opposite / hypotenuse
  • cos θ = adjacent / hypotenuse
  • tan θ = opposite / adjacent

To find the angle itself, use the inverse functions: θ = sin⁻¹(opposite / hypotenuse), θ = cos⁻¹(adjacent / hypotenuse) or θ = tan⁻¹(opposite / adjacent).

Example: find the angles from two sides. With a = 6 and b = 8, the base angle α has opposite side a and adjacent side b:
α = tan⁻¹(6 / 8) ≈ 36.87°
β = 90° − 36.87° = 53.13°

The two acute angles always add up to 90°. In radians, the second angle is π/2 − θ. For example, α ≈ 0.6435 rad gives β ≈ 0.9273 rad.

Example: find the sides from one side and an angle. With hypotenuse c = 10 and α = 30°:
a = c × sin 30° = 10 × 0.5 = 5
b = c × cos 30° ≈ 8.660

Area, Perimeter and Altitude

The two legs of a right triangle are perpendicular, so one leg is the base and the other is the height.

  • Area: A = ½ × a × b
  • Perimeter: P = a + b + c
  • Altitude to the hypotenuse: h = (a × b) / c. This is the perpendicular distance from the right angle to the hypotenuse.

Example with a = 6, b = 8, c = 10:
A = ½ × 6 × 8 = 24 square units
P = 6 + 8 + 10 = 24 units
h = (6 × 8) / 10 = 4.8 units

The calculator also works backwards. Enter an area of 6 and a perimeter of 12, and it returns the 3-4-5 triangle.

Special Right Triangles

Two right triangles have fixed side ratios, so you can solve them without a calculator. The solver recognises them and shows a badge when your triangle matches one.

Special right triangles: 45-45-90 triangle with sides x, x, x√2 and 30-60-90 triangle with sides x, x√3, 2x

45°–45°–90° Triangle (Isosceles Right Triangle)

Both legs are equal and the angles are 45°, 45° and 90°. The sides are in the ratio 1 : 1 : √2.
If each leg is 6, the hypotenuse is 6√2 ≈ 8.485.

30°–60°–90° Triangle

The sides are in the ratio 1 : √3 : 2. The shortest side is opposite the 30° angle, and the hypotenuse is twice the shortest side.
If the shortest side is 5, the other leg is 5√3 ≈ 8.660 and the hypotenuse is 10.

The 3-4-5 Rule

Sides of 3, 4 and 5 always make a right triangle, because 3² + 4² = 9 + 16 = 25 = 5². Builders use this to check a square corner. They mark 3 units along one edge and 4 units along the other. If the diagonal measures exactly 5, the corner is 90°. Any multiple works too, such as 6-8-10 or 9-12-15.

Worked Example: Solve a Right Triangle Step by Step

Solve the right triangle with legs a = 6 and b = 8.

  1. Hypotenuse: c = √(6² + 8²) = √100 = 10
  2. Base angle: α = tan⁻¹(6/8) ≈ 36.87°
  3. Top angle: β = 90° − 36.87° = 53.13°
  4. Area: A = ½ × 6 × 8 = 24 square units
  5. Perimeter: P = 6 + 8 + 10 = 24 units
  6. Altitude to the hypotenuse: h = 48 / 10 = 4.8 units

Enter a = 6 and b = 8 in the calculator above to see the same steps with the diagram.

Common Mistakes When Solving Right Triangles

  • Using the Pythagorean theorem on a triangle without a 90° angle. It only works for right triangles.
  • Treating a leg as the hypotenuse. The hypotenuse is always opposite the right angle and is the longest side.
  • Mixing up opposite and adjacent. They change depending on which acute angle you measure from.
  • Calculator in the wrong angle mode. sin 30 in radians mode is not 0.5. Match the mode to your angle unit.
  • Mixing units. Enter all sides in the same unit, and remember that area is in square units.
  • Subtracting in the wrong order. For a missing leg, use c² − b², not b² − c².

Related Lessons and Tools

Frequently Asked Questions

How do you calculate a right triangle?

You need two values, such as two sides or one side and one acute angle. Use the Pythagorean theorem (a² + b² = c²) to find a missing side, and sine, cosine or tangent to find the angles. The other acute angle is 90° minus the first. The calculator above does all of this and shows each step.

What two values do I need to solve a right triangle?

Any two compatible values: two sides, one side and an acute angle, or the area and the perimeter. Two angles alone are not enough, because they fix the shape but not the size.

How do I calculate the hypotenuse?

Square both legs, add them and take the square root: c = √(a² + b²). For legs 6 and 8, c = √100 = 10.

How do I find a missing side of a right triangle?

If you know the hypotenuse and one leg, use a = √(c² − b²). For c = 13 and b = 5, a = 12. If you know one side and an angle, use sine, cosine or tangent instead.

What is the 3-4-5 rule for a right triangle?

A triangle with sides 3, 4 and 5 is always a right triangle, because 3² + 4² = 5². It is used to check that a corner is exactly 90°, and any multiple such as 6-8-10 works the same way.

How do you check that an angle is 90 degrees?

Measure the three sides of the triangle. If the square of the longest side equals the sum of the squares of the other two (a² + b² = c²), the angle opposite the longest side is exactly 90°.

Is a right triangle always 45-45-90?

No. Only an isosceles right triangle has angles of 45°, 45° and 90°. A right triangle only needs one 90° angle. The other two can be any pair that adds up to 90°, such as 30° and 60°, or 36.87° and 53.13°.

Can I use radians instead of degrees?

Yes. Switch the angle unit to radians and enter values such as 0.5236 or expressions such as pi/6. In radians, the two acute angles add up to π/2.

Does this calculator solve every type of triangle?

No. It is built for right triangles, which have one 90° angle. For triangles without a right angle you need the law of sines or the law of cosines — our law of sines and cosines worksheet covers the first of those, including the ambiguous case.