Skip to main content

Triangle Calculator

Geometry

Every side, angle, and the area from what you know.

Geometry

Triangle Calculator

Solve SSS, SAS, ASA, and AAS triangles with the law of sines and law of cosines.

Side a is opposite angle A, side b opposite B, and side c opposite C. SSA is not offered because it can produce two different triangles (the ambiguous case).

Triangle

Scalene

side a

3

side b

4

side c

5

∠A

36.87°

∠B

53.13°

∠C

90°

Area
6
Perimeter
12
Angle sum
180°

Area uses Heron's formula, so it stays accurate for obtuse triangles where a height is hard to place.

Embed this calculator

Put this calculator on your own site with the snippet below. The frame contains the tool only, reports its own height, and carries a visible link back to the full page. Embedding is free; keep the attribution link as it is, and do not wrap the frame in a way that hides it.

Preparing the embed code for this page...

What This Calculator Does

The Triangle Calculator solves a triangle from the information you have: three sides (SSS), two sides and the included angle (SAS), two angles and the side between them (ASA), or two angles and a side opposite one (AAS). It returns every remaining side and angle, plus area and perimeter.

How It Works

SSS uses the law of cosines to find each angle from the side lengths. SAS uses the law of cosines to find the third side, then the law of sines for the angles. ASA and AAS use the fact that the angles sum to 180°, then the law of sines to scale the sides. Area comes from Heron’s formula, which needs only the three sides and stays accurate for obtuse triangles.

Example

A 3–4–5 triangle has a right angle opposite the 5. The law of cosines gives angles of about 36.87°, 53.13°, and 90°, an area of 6 square units, and a perimeter of 12. Because all three sides differ, it is scalene.

Formula

Law of cosines
c² = a² + b² − 2ab cos C

Used for SSS and SAS; it reduces to Pythagoras when C = 90°.

Law of sines
a / sin A = b / sin B = c / sin C

Used for ASA and AAS once the third angle is known.

Heron’s formula
Area = √(s(s − a)(s − b)(s − c)), s = (a + b + c)/2

Reading the Results

Sides and angles

Side a is opposite angle A, side b opposite B, and side c opposite C. The three angles always sum to 180°.

Area

Computed with Heron’s formula, so no height is needed and obtuse triangles are handled correctly.

Triangle type

Equilateral when all sides match, isosceles when two match, scalene when none do. It describes the shape, not whether the triangle is right-angled.

Sources and References

  • NIST Digital Library of Mathematical Functions

    Law of sines and law of cosines

    DLMF §4.36 and §4.37 give the triangle identities used here.

References identify the method or data behind this calculator. Where a standard or tariff changes, the current edition applies, and the assumptions stated above take precedence over a remembered figure.

Frequently Asked Questions

Why can’t I solve a triangle with two sides and a non-included angle?

That case (SSA) can produce zero, one, or two different triangles — the ambiguous case. A calculator that silently returns one answer can be wrong, so this tool does not offer it. Use the law of sines and check both solutions by hand.

How do I know which side is a, b, or c?

The convention is that side a is opposite angle A, side b opposite B, and side c opposite C. For ASA, side c is the side between angles A and B. Keep that labelling consistent or the results will not match your diagram.

What does it mean if the calculator rejects my sides?

The triangle inequality requires every pair of sides to add up to more than the third. If 2, 3, and 8 are entered, no triangle exists, because 2 + 3 is less than 8.

Does the area formula work for obtuse triangles?

Yes. Heron’s formula depends only on side lengths, so it works for acute, right, and obtuse triangles alike. That is why it is used here instead of the half-base-times-height form.