Triangle Formula Calculator
Enter the three side lengths of a triangle you already know completely, and this calculator shows every formula result at once: perimeter, semi-perimeter, area by Heron’s formula with a base-times-height cross-check, all three angles by the law of cosines, the three heights, and the triangle’s classification by sides and by angles. It does not solve for missing sides or angles: if a side or an angle is still unknown, that is a different job, and the solver page linked below is the right tool for it.
All three sides must use the same unit, and the height, when given, must be the perpendicular height to side a. Angles are in degrees. A triangle whose largest angle is within 0.005 degrees of 90 degrees is classified as right.
Quick Answer
For sides 3, 4, and 5 with height 4 to side a: perimeter 12.00, semi-perimeter 6.00, Heron area 6.00 sq units (the base-times-height check also gives 6.00), angles 36.87, 53.13, and 90.00 degrees, heights 4.00, 3.00, and 2.40, and type scalene right triangle. Those are the pre-filled values above: click Calculate to reproduce them.
- Quick Answer
- How to use this calculator
- Worked example, checked against this exact tool
- Heron's formula, explained
- The law of cosines finds the angles
- The triangle inequality, and why degenerate triangles fail
- Formula page or solver page: which one do you need
- What competing calculators miss
- Frequently asked questions
- Add This Calculator to Your Website
- References
How to use this calculator
Enter all three sides in the same unit. Units are deliberately generic: inches, centimeters, meters, or any other length unit all work, because every output is in that unit or its square, and mixing units would silently corrupt every result. The height field is optional. If you know it, enter the perpendicular height to side a only, and the tool adds a base-times-height area as a cross-check on the Heron area. If you leave it blank, you still get the full Heron result, all three angles, all three heights, and the classification. Results stay hidden until you click Calculate, and Reset clears the inputs and the result.
Worked example, checked against this exact tool
Take sides 3, 4, and 5. Perimeter is 3 plus 4 plus 5, giving 12.00, so the semi-perimeter is 6.00. Heron area is the square root of 6 times 3 times 2 times 1, which is the square root of 36, giving 6.00 sq units. Angle A is arccos of (16 plus 25 minus 9) divided by 40, giving 36.87 degrees. Angle B is arccos of (9 plus 25 minus 16) divided by 30, giving 53.13 degrees. Angle C is 180 minus those two, giving 90.00 degrees. Heights are twice the area divided by each side: 4.00 to side a, 3.00 to side b, and 2.40 to side c. All three sides differ, so it is scalene, and the largest angle is 90 degrees, so it is right. Enter 3, 4, 5, and height 4 to reproduce these figures exactly.
| Sides | Perimeter | Heron area | Type |
|---|---|---|---|
| 3, 4, 5 | 12.00 | 6.00 | Scalene right |
| 5, 5, 5 | 15.00 | 10.83 | Equilateral acute |
| 5, 6, 7 | 18.00 | 14.70 | Scalene acute |
| 7, 8, 9 | 24.00 | 26.83 | Scalene acute |
| 2.5, 3.5, 4.5 | 10.50 | 4.35 | Scalene obtuse |
Heron's formula, explained
When you know three sides but no height, Heron's formula finds the area from the semi-perimeter, which is half the perimeter: area equals the square root of s times (s minus a) times (s minus b) times (s minus c). It works for every triangle, including scalene ones where no height is obvious, and it needs no angle at all. The most common student error is feeding the full perimeter into the formula instead of the semi-perimeter, which inflates the area badly: for 3, 4, and 5, using 12 in place of 6 gives the square root of 12 times 9 times 8 times 7, or about 77.77, instead of the correct 6.00. If your hand calculation looks far too large, check s first. The Heron's formula calculator covers the area-only version of this job; this page adds perimeter, angles, heights, and classification around the same formula.
The law of cosines finds the angles
Three sides determine a triangle completely, a fact geometry calls SSS congruence, so the angles are fixed once the sides are known and no angle input is needed. The tool computes two angles from the law of cosines, for example angle C equals arccos of (a squared plus b squared minus c squared) divided by twice a times b, with the cosine values clamped to the range minus 1 to 1 so rounding at near-degenerate triangles cannot produce an invalid arccos, and takes the third angle as 180 degrees minus the other two, which also guarantees the three angles sum to exactly 180 degrees in the display. The largest angle decides the angle classification: within 0.005 degrees of 90 is right, over 90 is obtuse, and all under 90 is acute. That tolerance is stated in the tool note because a triangle at 89.998 degrees is, for homework purposes, right, and a reader who sees it classified as acute without explanation would reasonably think the tool was wrong.
Combined with the side classification, equilateral (all three equal), isosceles (exactly two equal in the tool's reading, with equilateral handled as its own case first), and scalene (all different), every triangle gets one of nine possible types. Heights follow from the area rather than from any measurement: height to a side equals twice the area divided by that side, which is why the tool can report all three heights from sides alone. The same semi-perimeter reappears in the inradius formula (area divided by s) and the circumradius formula (a times b times c divided by four times the area), but those radii are not outputs here: they belong to a solver-style page, and adding them would blur this page's formula-display job.
The triangle inequality, and why degenerate triangles fail
A valid triangle needs a plus b greater than c, a plus c greater than b, and b plus c greater than a. Sides 2, 3, and 5 fail (2 plus 3 equals 5): the two short sides just lie flat along the long one with zero area, a degenerate case, not a triangle. The tool rejects such inputs and shows which inequality broke, with the substituted numbers for the a-plus-b case. A near-miss such as 2, 3, and 4.99 passes but has a very small area, which is correct, not a bug: as the longest side approaches the sum of the other two, the triangle flattens and the area approaches zero. Decimal side lengths are accepted throughout, and a zero or negative side is rejected before any formula runs.
Formula page or solver page: which one do you need
Keep the distinction sharp, because the two pages in this batch share an SSS overlap and are easy to confuse. This page starts from a complete triangle: all three sides known, every formula result displayed, with the substituted Heron numbers written out so a student can follow each step. The triangle sides calculator starts from an incomplete triangle: two sides and an angle, or one side and two angles, or a right triangle with two known values, and it solves for what is missing, including the ambiguous SSA case with zero, one, or two solutions. If you can already list a, b, and c, stay here. If something is missing, go there. The special case of a 45-45-90 triangle has its own shortcut page, the 45-45-90 triangle calculator, for the one triangle where the side ratios are fixed.
What competing calculators miss
The full solvers are the strongest competitors and also the clearest contrast. Calculator.name and PrimeCalculator solve SSS, SAS, ASA, and more, with diagrams, medians, inradius, and circumradius, and PrimeCalculator shows solution steps. SmartOnlineCalculator and Calc-Plus do the same SSS job with classification and heights, and Calc-Plus adds radii. Their weakness for this query is scope, not accuracy: a student searching for triangle formulas gets a solver that answers a different question, with the formula itself buried under solver modes, diagrams, and extra outputs. The Heron-only pages go the other way: MiniWebTool and the ShortCalc Heron page show area, altitudes, and radii with diagram toggles, but no perimeter-and-angles formula readout, and AI Online Calculator's triangle area page stops at area, perimeter, angles, and type without the heights or the substituted formula line.
This page wins on the formula-display job specifically: it takes only complete sides, shows the Heron substitution with numbers (not just the abstract formula), adds the base-times-height cross-check with its side-a pairing stated in the label, names the failing inequality instead of a generic error, and states the 0.005 degree right-triangle tolerance that near-right cases need. It deliberately does not add solver modes, medians, or radii: those are the solver page's job, and copying them here would recreate the exact duplication this batch screened against.
Frequently asked questions
Area equals the square root of s times (s minus a) times (s minus b) times (s minus c), where s is the semi-perimeter, half the perimeter. It finds area from three sides with no height needed.
Use the law of cosines: angle C equals arccos of (a squared plus b squared minus c squared) divided by twice a times b. The tool computes all three angles, with the third taken as 180 degrees minus the other two.
By sides: equilateral, isosceles, scalene. By angles: right, acute, obtuse. A 3-4-5 triangle is a scalene right triangle, and a 5-5-5 triangle is an equilateral acute triangle.
The sum of any two sides must exceed the third: a plus b greater than c, a plus c greater than b, and b plus c greater than a. Sides 2, 3, and 5 fail and cannot form a triangle.
The height entered is probably not perpendicular to side a, or not the height for that base. Heron's value is the reliable one, because it comes from the three sides alone.
It is the input to Heron's formula and also appears in the inradius and circumradius formulas. Using the full perimeter in Heron's formula instead gives a badly inflated area.
Yes. The tool accepts any positive decimal values, and rejects zero or negative sides before any formula runs.
From area: height equals twice the area divided by the base. The tool shows all three heights automatically, one for each side.
No. This page takes a complete triangle with all three sides known and displays every formula result. A solver starts from missing sides or angles and finds them; use the triangle sides calculator for that job.
Add This Calculator to Your Website
Embed this calculator on your own site with the code below. Pick a size to preview it live, then copy the code.
Powered by Calculator Zilo
References
- Khan Academy. Heron's formula (semi-perimeter definition and worked Heron examples, including sides 9, 11, and 16). Accessed October 24, 2026.
- LibreTexts, Cosumnes River College, Math 375 Pre-Calculus. 11.3.1 Resources and Key Concepts: Areas of Non-Right Triangles (Heron's formula, the semi-perimeter versus full-perimeter error, and the included-angle area formula). Accessed October 24, 2026.
- Alabama Access Distance Learning, Precalculus. 5.08 Area of an Oblique Triangle (derivation of Heron's formula from the law of cosines and the base-times-height area). Accessed October 24, 2026.
- The Math Doctors. Area of a Triangle: Heron's Formula (geometric derivation via inradius, showing why area equals the semi-perimeter times the inradius). Accessed October 24, 2026.
- Fiveable, College Algebra Study Guide. Non-Right Triangles: Law of Cosines and Heron's Formula (law of cosines, law of sines, and the step-by-step Heron procedure with the 6-8-10 example). Accessed October 24, 2026.
