📐 Triangle Solver (Law of Sines & Cosines)
Enter any three values (with at least one side) and get the complete triangle — all sides, all angles, area and perimeter — drawn to scale.
Enter any 3 values (at least one side). Angles in degrees.
Solves from any valid combination — three sides (SSS), two sides and the included angle (SAS), two angles and a side (ASA/AAS), or two sides and a non-included angle (SSA, which can give two triangles). Uses the laws of sines and cosines; angles sum to 180°. 🔒 In your browser.
How the triangle solver (law of sines & cosines) works
Give three of the six measurements — sides a, b, c and angles A, B, C (each angle opposite its same-letter side) — and the tool finds the rest. Three sides (SSS) or two sides and the included angle (SAS) are solved with the law of cosines; two angles and a side (ASA or AAS) use the angle sum and the law of sines; two sides and a non-included angle (SSA) use the law of sines and can yield two valid triangles (the "ambiguous case"), both of which are shown. Area comes from ½·a·b·sin C.
Angles are in degrees and must sum to 180°. The SSA case is genuinely ambiguous — a given side, another side and a non-included angle can describe two different triangles, one triangle, or none, depending on whether the side is long enough to "reach"; the solver reports each valid answer rather than silently picking one.
Frequently asked questions
How do I solve a triangle?
You need any three measurements including at least one side. Depending on which three you have, you use the law of cosines (for SSS or SAS) or the law of sines (for ASA, AAS or SSA) to find the missing sides and angles. This tool detects the case and solves it.
What is the law of sines?
a/sin A = b/sin B = c/sin C — each side divided by the sine of its opposite angle gives the same ratio. It solves triangles when you know a side and its opposite angle plus one more value (ASA, AAS, SSA).
What is the law of cosines?
c² = a² + b² − 2ab·cos C (and cyclic versions). It finds the third side from two sides and the included angle (SAS), or any angle from all three sides (SSS).
What is the ambiguous (SSA) case?
When you know two sides and an angle not between them, the known side may be long enough to form the triangle in two different ways — giving two valid triangles. The solver shows both; if the side is too short it reports no solution.
Why do the angles have to add up to 180°?
In Euclidean (flat) geometry the interior angles of every triangle sum to exactly 180°, so once two angles are known the third is fixed. The solver uses this and rejects angle sets that break it.
Can I enter a right triangle?
Yes — enter 90 for one angle, or three sides like 3, 4, 5. A right triangle is just a normal case for the laws of sines and cosines; the tool will confirm the 90° angle.