Triangle Calculator

Solve a triangle from three sides, two sides and an angle, or two angles and a side, with area, perimeter, heights, type and both SSA answers.

Reviewed · How we build and check our calculators

Your details

Side a faces angle A, side b faces angle B and side c faces angle C.

The missing parts

A = 36.87°, B = 53.13°, C = 90°

Right scalene triangle

Area
6 cm²
Perimeter
12 cm
Height onto side a
4 cm
Height onto side b
3 cm
Height onto side c
2.4 cm
Inradius
1 cm
Largest circle inside
Circumradius
2.5 cm
Circle through the corners

The angles of every triangle add up to 180°, and the longest side always faces the largest angle.

Every side and angle

PartValue
Side a3 cm
Side b4 cm
Side c5 cm
Angle A36.87°
Angle B53.13°
Angle C90°

How the triangle calculator works

Solve any triangle from three of its parts: three sides, two sides and an angle, or two angles and a side. You get every side and angle, the area, perimeter, heights and the type, and both answers when two triangles fit.

Formula

Law of cosines: c² = a² + b² − 2ab cos C. Law of sines: a ÷ sin A = b ÷ sin B = c ÷ sin C. A + B + C = 180°. Area = ½ab sin C, or Heron's √(s(s−a)(s−b)(s−c)). Height onto a side = 2 × area ÷ that side.

  1. 1

    Find an angle from the three sides

    For sides 3, 4 and 5 cm: cos C = (3² + 4² − 5²) ÷ (2 × 3 × 4) = 0, so C = 90°.

  2. 2

    Find the other angles

    cos A = (4² + 5² − 3²) ÷ (2 × 4 × 5) = 0.8, so A = 36.87°, and B = 180° − 90° − 36.87° = 53.13°.

  3. 3

    Work out the area and perimeter

    Area = ½ × 3 × 4 × sin 90° = 6 cm², and the perimeter is 3 + 4 + 5 = 12 cm.

  4. 4

    Find the heights

    Each height is 2 × 6 ÷ its side: 4 cm onto a, 3 cm onto b and 2.4 cm onto c. It is a right scalene triangle.

Worked example

The calculator opens with these values

What do you know?
Three sides (SSS)
Side a
3
Side b
4
Side c
5
Unit of the lengths
Centimeters (cm)

The missing parts

A = 36.87°, B = 53.13°, C = 90°

Special and well-known triangles

The 45-45-90 and 30-60-90 triangles appear in set squares, roof pitches and exam questions because their sides follow fixed ratios. Scale any row up: a 30-60-90 triangle with a 10 cm short side has sides 10, 10√3 ≈ 17.32 and 20 cm.

Well-known triangles solved from their three sides
TriangleSides a, b, cAngles A, B, CAreaType
Equilateral1, 1, 160°, 60°, 60°0.433 square unitsAcute equilateral triangle
45-45-901, 1, √245°, 45°, 90°0.5 square unitsRight isosceles triangle
30-60-901, √3, 230°, 60°, 90°0.866 square unitsRight scalene triangle
3-4-53, 4, 536.87°, 53.13°, 90°6 square unitsRight scalene triangle
5-12-135, 12, 1322.62°, 67.38°, 90°30 square unitsRight scalene triangle
Isosceles5, 5, 836.87°, 36.87°, 106.26°12 square unitsObtuse isosceles triangle
Scalene7, 8, 948.19°, 58.41°, 73.4°26.8328 square unitsAcute scalene triangle
Obtuse4, 5, 824.15°, 30.75°, 125.1°8.1815 square unitsObtuse scalene triangle

Which rule solves which triangle

The calculator picks the method from what you know. By hand, follow the same order.

  • Three sides (SSS): use the law of cosines for one angle, then again or the angle sum for the rest.
  • Two sides and the angle between them (SAS): the law of cosines gives the third side first.
  • Two angles and a side (ASA or AAS): subtract from 180° for the third angle, then use the law of sines.
  • Two sides and an angle not between them (SSA): use the law of sines, then check whether a second triangle fits.
  • A right triangle: the Pythagorean theorem and sin = opposite ÷ hypotenuse, cos = adjacent ÷ hypotenuse, tan = opposite ÷ adjacent are quicker.

Rules every triangle follows

These checks catch most mistakes in a drawing or a set of measurements.

  • Each side is shorter than the other two added together: 2, 3 and 6 cannot make a triangle.
  • An outside angle equals the two inside angles opposite it added together.
  • Triangles with the same angles are similar, so their sides keep the same ratio. A 2 m pole with a 3 m shadow means a tree with an 18 m shadow is 2 ÷ 3 × 18 = 12 m tall.

Common questions

What is the ambiguous case (SSA)?

When you know two sides and an angle that is not between them, the third side is not always fixed: the shorter side can meet the base at two points. With a = 3, b = 4 and A = 30°, angle B is 41.81° or 138.19°, and the calculator shows both triangles.

Why can't I solve a triangle from three angles?

Three angles fix the shape but not the size: a small and a large triangle can have the same angles. You need at least one side.

How do I tell if a triangle is right, acute or obtuse?

Look at the largest angle: exactly 90° is right, under 90° is acute and over 90° is obtuse. From the sides, compare c² with a² + b² for the longest side c.

Which side is a, b or c?

Each side carries the letter of the angle across from it: side a faces angle A, and so on.

Area Calculator

Area and perimeter of rectangles, triangles, circles, polygons and more

Add this calculator to your website

Free for blogs, schools and businesses. Paste this code into your page; the calculator works inside it, with no ads and no tracking. Please keep the credit line.