Free Triangle Calculator
Solve any triangle: calculate unknown sides, angles, area, perimeter, and height. Supports the law of sines, law of cosines, right triangles, and Heron's formula.
About This Triangle Calculator
The Triangle Calculator solves any triangle given sufficient information. Enter any combination of sides and angles and the calculator will determine all remaining values — including the third angle, all three sides, area, perimeter, and height. It applies the three fundamental triangle-solving methods: the Pythagorean theorem (right triangles), the law of sines, and the law of cosines.
The Formulas
Which formula is applied depends on what information you provide. The law of cosines is the most general formula and reduces to the Pythagorean theorem when the included angle is 90°. The law of sines is more efficient when two angles are known.
When to Use Each Approach
- •SSS (three sides known): use law of cosines to find angles, then Heron's for area
- •SAS (two sides + included angle): use law of cosines to find the third side
- •ASA or AAS (two angles + any side): use angle sum then law of sines
- •SSA (two sides + non-included angle): use law of sines — watch for ambiguous case
- •Right triangle (one angle = 90°): use Pythagorean theorem + basic trig
Privacy Notice
All calculations run in your browser. No data is transmitted or stored. See our Privacy Policy.
When to Use This Calculator
Solve for unknown sides and angles in any triangle using the law of sines and cosines, and verify your hand-calculated answers.
Calculate roof truss angles, rafter lengths, and hip-to-ridge dimensions for construction projects where triangles define the structure.
Determine the distance to an inaccessible point or the area of a triangular land parcel using the angle and distance measurements you can take.
Calculate distances and bearings using triangulation when two reference points and angles are known — the classic navigation technique used at sea and in aviation.
Calculate the exact dimensions of triangular design elements, vector graphics, and architectural features to ensure precise proportions.
💡 Pro Tips
The ambiguous SSA case (two sides and a non-included angle) can produce 0, 1, or 2 valid triangles. Always check: if the given angle is obtuse, there can be at most one solution. If the side opposite the angle is shorter than the other given side and the angle is acute, there may be two solutions. Real-world surveying problems use this distinction constantly.
The law of cosines is a generalisation of the Pythagorean theorem. When angle C = 90°, cos(90°) = 0, so c² = a² + b² − 0, which is exactly the Pythagorean theorem. This relationship makes the law of cosines the universal formula for all triangles — you never need to check if a triangle is right-angled before applying it.
For very obtuse triangles (angle close to 180°), the opposite side becomes very long relative to the others. This is why long, thin triangles are numerically unstable in geometric algorithms — small measurement errors in an obtuse angle create large errors in the computed side lengths. In engineering, avoid designs that rely on very obtuse triangles.
Heron's formula can be numerically unstable for very flat triangles (where one side is nearly equal to the sum of the other two). The Kahan variant — which rearranges the formula to avoid catastrophic cancellation — is used in professional CAD and GIS software for better numerical accuracy.
Frequently Asked Questions
Related Calculators
Your input is processed locally in your browser and is never stored, transmitted, or shared with any server. See our Privacy Policy.