Khayyam Math

Heron's formula: area of a triangle from its three sides

A two-thousand-year-old formula that gives the area of any triangle directly from the side lengths — no height needed.

ABCa = 7b = 6c = 5Triangle with sides 5, 6, 7s = (5 + 6 + 7) / 2 = 9A = √(s(s−a)(s−b)(s−c)) = √(9 · 4 · 3 · 2) = √216 = 6√6 ≈ 14.697

Try this live →

What this shows

Heron's formula computes the area of a triangle from the three side lengths a, b, c without ever needing to know any of its angles or any of its altitudes. Let

    s = (a + b + c) / 2

be the semi-perimeter — half the perimeter — and then

    A = √(s · (s − a) · (s − b) · (s − c))

For the 5-6-7 triangle in the figure:

    s        = (5 + 6 + 7) / 2  = 9
    s − a    = 9 − 5 = 4
    s − b    = 9 − 6 = 3
    s − c    = 9 − 7 = 2
    product  = 9 · 4 · 3 · 2 = 216
    A        = √216 = 6√6 ≈ 14.697

The formula is named after Hero (or Heron) of Alexandria, who proved it in his Metrica around 60 CE, though there is evidence Archimedes knew it three centuries earlier. It works for every real triangle — equilateral, isosceles, scalene, right-angled or obtuse — provided the three lengths actually form a triangle (each side strictly less than the sum of the other two).

Where it shows up

Heron's formula is the working tool whenever you know three side lengths but not the angles: surveying a plot of land from three measured fence-lengths, computing the area of an irregular polygon by triangulating it, or sanity-checking a triangle in a CAD drawing where the angle annotations might be wrong.

The formula also lets you check whether three given lengths even *form* a valid triangle. If the product s(s−a)(s−b)(s−c) comes out negative or zero, one of the lengths is too long relative to the other two — the triangle inequality fails and no triangle exists.

Frequently asked questions

Why no height?

The usual area formula A = ½·base·height needs you to know an altitude, which often isn't given. Heron's formula trades the altitude for an extra side length, and you usually have all three sides.

Does it work for degenerate triangles?

If one side equals the sum of the other two, the three points are colinear — no real triangle. Heron's formula returns zero, which is the right answer: a degenerate triangle has zero area.

Where does the formula come from?

Several derivations exist. The classical one uses the Pythagorean theorem on the altitude dropped from one vertex. A more modern derivation expands the cross-product magnitude |b−a × c−a| / 2 and rearranges. Either way you end up at the same symmetric expression in a, b, c.

Is there a 3D analogue?

Yes — the Cayley-Menger determinant generalises Heron's formula to compute the volume of a tetrahedron from its six edge lengths. The expression is uglier but follows the same idea: edge lengths alone determine the simplex's content.

Related topics