Triangle Calculator
Calculate the area, perimeter and angles of any triangle from its three sides (Heron’s formula), or the area from base and height. The calculator also tells you the type of triangle.
- 100% free
- No signup
- Runs in your browser
How to use
- If you know all three sides, enter them as side a, b and c and click Calculate.
- Read the area, the perimeter, the three angles and the triangle type in the table below the result.
- If you know a base and the height to that base, use the second calculator instead.
- Use the same unit for all lengths. The area is in square units of that unit.
Heron’s formula
Heron’s formula gives the area from the three sides alone. First compute the semi-perimeter s = (a + b + c) / 2; the area is then √(s(s − a)(s − b)(s − c)). It works for every triangle, including irregular (scalene) ones.
The angles come from the law of cosines: cos A = (b² + c² − a²) / (2bc), and the same for B and C. The three angles always add up to 180°.
Triangle formulas
| Quantity | Formula |
|---|---|
| Area from base and height | A = ½ × b × h |
| Area from three sides | A = √(s(s − a)(s − b)(s − c)) |
| Semi-perimeter | s = (a + b + c) / 2 |
| Perimeter | P = a + b + c |
| Angle A (opposite side a) | A = arccos((b² + c² − a²) / (2bc)) |
Types of triangles
By sides: equilateral (all three sides equal), isosceles (two sides equal) or scalene (all sides different).
By angles: acute (all angles under 90°), right-angled (one angle of exactly 90°) or obtuse (one angle over 90°). A triangle is right-angled when a² + b² = c² for its longest side c.
Examples
| Example | Result |
|---|---|
| Sides 3, 4 and 5 | Area 6, perimeter 12, angles 36.87°, 53.13° and 90° (right-angled) |
| Sides 5, 5 and 8 | Area 12, angles 36.87°, 36.87° and 106.26° (isosceles, obtuse) |
| Sides 7, 8 and 9 | s = 12, area = √(12 × 5 × 4 × 3) = √720 ≈ 26.83 |
| Base 10 and height 6 | Area = ½ × 10 × 6 = 30 |