Skip to content

Triangle Area Calculator

Area of a triangle from base and height, three sides, two sides and an angle, or vertex coordinates — plus all three heights.

Your details

Unit system
I know

Perpendicular distance from the base (or its extension) to the opposite vertex.

Results update as you type

Area

30 in²

Step-by-step solution
  1. A = b × h / 2 = 10 in × 6 in / 2 = 30 in²

Half of base times height is the formula everyone remembers, but real problems rarely hand you a height. This triangle area calculator works from whatever you actually know:

  • the base and the height;
  • the three sides, using a numerically stable form of Heron's formula;
  • two sides and the angle between them;
  • the coordinates of the three vertices, using the shoelace (determinant) formula.

Whenever the three sides can be determined, it also returns the three heights (altitudes), the perimeter, the three angles and the type of triangle (scalene, isosceles or equilateral; acute, right or obtuse). In base-and-height mode you can also run it backwards: choose Solve for → Height and enter a known area to get the missing height, or solve for the base.

Inputs are checked before anything is computed. Three lengths that violate the triangle inequality, an angle of 0° or 180°, or three points on one line produce a clear message rather than a meaningless zero. For the perimeter of other shapes, see the perimeter calculator; for squares, circles and polygons, the area calculator.

How to use this calculator

  1. Choose what you know: base and height, three sides, two sides and the included angle, or coordinates.
  2. Enter the values. Lengths have a unit menu (mm to miles); coordinates are plain numbers and may be negative.
  3. For two sides and an angle, the angle must be the one between the two sides, in degrees.
  4. Read the area at the top, then the heights, perimeter, angles and type of triangle.
  5. To find a height or a base from a known area, use Solve for in base-and-height mode.

The formula

Base and height: A=12bhA = \frac{1}{2} b h, where hh is perpendicular to the base bb.

Three sides (Heron): with the semi-perimeter s=a+b+c2s = \frac{a + b + c}{2},

A=s(s−a)(s−b)(s−c)A = \sqrt{s(s - a)(s - b)(s - c)}

The calculator uses Kahan's rearrangement, which gives the same value but avoids rounding trouble for thin triangles. With the sides sorted so that a≥b≥ca \ge b \ge c:

A=14(a+(b+c))(c−(a−b))(c+(a−b))(a+(b−c))A = \frac{1}{4}\sqrt{(a + (b + c))(c - (a - b))(c + (a - b))(a + (b - c))}

Two sides and the included angle: A=12absin⁡CA = \frac{1}{2} a b \sin C. The third side follows from the law of cosines, c2=a2+b2−2abcos⁡Cc^2 = a^2 + b^2 - 2ab\cos C.

Coordinates A(x1,y1)A(x_1, y_1), B(x2,y2)B(x_2, y_2), C(x3,y3)C(x_3, y_3):

A=12∣x1(y2−y3)+x2(y3−y1)+x3(y1−y2)∣A = \frac{1}{2}\left| x_1(y_2 - y_3) + x_2(y_3 - y_1) + x_3(y_1 - y_2) \right|

Heights: each height is twice the area divided by the side it falls on, ha=2Aah_a = \frac{2A}{a}, hb=2Abh_b = \frac{2A}{b}, hc=2Ach_c = \frac{2A}{c}.

Worked example

Base and height. A base of 10 cm and a height of 6 cm give A=10×62=30A = \frac{10 \times 6}{2} = 30 cm².

Three sides. For the 13-14-15 triangle, s=21s = 21 and A=21×8×7×6=7056=84A = \sqrt{21 \times 8 \times 7 \times 6} = \sqrt{7056} = 84. Its heights are ha=16813≈12.92h_a = \frac{168}{13} \approx 12.92, hb=16814=12h_b = \frac{168}{14} = 12 and hc=16815=11.2h_c = \frac{168}{15} = 11.2. Sides of 10, 15 and 7 give s=16s = 16 and A=864≈29.39A = \sqrt{864} \approx 29.39.

Two sides and an angle. Sides of 90 and 52 with an included angle of 102°: A=12×90×52×sin⁡102∘≈A = \frac{1}{2} \times 90 \times 52 \times \sin 102^\circ \approx 2,288.87, and the third side is about 112.92.

Coordinates. For A(1,1)A(1, 1), B(5,2)B(5, 2), C(2,6)C(2, 6): 12∣1(2−6)+5(6−1)+2(1−2)∣=12∣−4+25−2∣=9.5\frac{1}{2}|1(2 - 6) + 5(6 - 1) + 2(1 - 2)| = \frac{1}{2}|{-4} + 25 - 2| = 9.5 square units.

Height of a triangle

Every triangle has three heights, one per side: the perpendicular segment from a vertex to the opposite side (or to its extension, when the angle at the base is obtuse). Since the area is the same whichever side you call the base, A=12aha=12bhb=12chcA = \frac{1}{2} a h_a = \frac{1}{2} b h_b = \frac{1}{2} c h_c, so each height is h=2Asideh = \frac{2A}{\text{side}}. The longest side always has the shortest height. If you know the area and a base, the height is h=2Abh = \frac{2A}{b}: an area of 30 cm² on a base of 10 cm means a height of 6 cm.

Area of a triangle from its coordinates

With vertices on a grid, there is no need to measure anything. The shoelace formula (a 3 × 3 determinant) gives the area directly from the six coordinates. Its sign before the absolute value tells the orientation: positive when A→B→CA \to B \to C runs counter-clockwise. A result of zero means the three points are collinear — a quick way to test whether points lie on one line. The calculator also deduces the side lengths with the distance formula, then the heights and angles.

Area from the three sides, and needle-shaped triangles

Heron's formula needs no height and no angle, only the three sides. Computed naively, though, it loses accuracy for very thin "needle" triangles, because s−as - a subtracts two nearly equal numbers. William Kahan showed that sorting the sides and keeping his parentheses fixes this. For sides of 100,000, 100,000 and 1.00005 the correct area is 50,002.5, which the stable formula reproduces while a ten-digit calculator using the textbook version reports 50,010.0.

Frequently asked questions

How do I find the area of a triangle?

Multiply the base by the perpendicular height and divide by 2. A triangle with a 10 cm base and a 6 cm height has an area of 30 cm². Without a height, use the three sides, two sides and an angle, or the coordinates.

How do I find the area of a triangle from its three sides?

Use Heron’s formula: compute s = (a + b + c) / 2, then A = √(s(s − a)(s − b)(s − c)). For sides 13, 14 and 15, s = 21 and A = 84.

How do I calculate the height of a triangle?

Divide twice the area by the side the height falls on: h = 2A / side. In the 13-14-15 triangle (area 84), the height on the side of 14 is 12.

How do I find the area of a triangle from coordinates?

Use A = ½ |x₁(y₂ − y₃) + x₂(y₃ − y₁) + x₃(y₁ − y₂)|. For A(1, 1), B(5, 2) and C(2, 6) the area is 9.5 square units.

Why does the calculator say my sides do not form a triangle?

Each side must be shorter than the sum of the other two (the triangle inequality). Sides of 2, 3 and 6 fail because 2 + 3 < 6; sides of 2, 3 and 5 collapse into a flat line with zero area.

Sources

Last updated:

More Math calculators

People also use