ThisCalculator

Everyday

Triangle Area & Perimeter Calculator

Updated · Standard formula, shown below

Perimeter 18.00 m
Area
14.70 m²
Result
Side a
5 m
You entered
Side b
6 m
You entered

Triangle Area & Perimeter Calculator

This calculator finds both the area and perimeter of a triangle. You enter the lengths of the three sides, and it returns the perimeter (the sum of the sides) and the area (the space inside the triangle) using Heron’s formula. The perimeter is shown first as the headline answer, followed by the area.

Formula

The perimeter of a triangle is simply the sum of its three side lengths:

P = a + b + c

The area is calculated using Heron’s formula, which works for any triangle when you know all three sides:

s = (a + b + c) / 2

Area = √(s × (s − a) × (s − b) × (s − c))

Where:

  • a, b, c – the three side lengths (in consistent units, e.g., meters, feet, centimeters)
  • s – the semi-perimeter, half of the triangle’s perimeter
  • Area – the result in square units (e.g., m², ft², cm²)

Heron’s formula is special because it needs no height or angle—just the three sides. It works for acute, obtuse, and right triangles alike.

Worked Example

Using the default values from the calculator: a = 5 m, b = 6 m, c = 7 m.

Step 1 – Perimeter:

P = 5 + 6 + 7 = 18 m

Step 2 – Semi-perimeter:

s = 18 / 2 = 9 m

Step 3 – Heron’s formula:

Area = √(9 × (9 − 5) × (9 − 6) × (9 − 7))

Area = √(9 × 4 × 3 × 2) = √(216) ≈ 14.70 m²

The calculator displays Perimeter = 18.00 m and Area = 14.70 m², matching the above calculation.

When to Use This Calculator

You might need the perimeter and area of a triangle in many everyday situations:

  • Construction and carpentry – estimating the amount of flooring, paint, or roofing material for a triangular section.
  • Gardening and landscaping – figuring out how much soil or turf to buy for a triangular plot.
  • Geometry homework – checking answers or understanding how Heron’s formula works.
  • Fabric or art projects – calculating how much material is needed for a triangular piece.
  • Fencing or edging – knowing the total length of border needed for a triangular area.

Whenever you have the lengths of all three sides, this calculator gives you both values instantly. If you only know the base and height, use the simpler formula: Area = ½ × base × height.

How to Read the Results

The perimeter is a length—it tells you the total distance around the triangle. If you’re buying fencing, that’s the number you need. The area is a square measure—it tells you how much surface the triangle covers. If you’re buying grass seed or paint, that’s the number you need.

Be careful with units. If you input sides in meters, the perimeter comes out in meters and the area in square meters. If you input in feet, the area is in square feet. Mixing units (e.g., one side in meters and another in centimeters) will produce a wrong answer. Convert all sides to the same unit before entering them.

For very large or very small triangles, the calculator rounds to two decimal places. That’s usually enough for practical purposes, but for precise engineering work, you might want to keep more decimal places.

Common Mistakes and Pitfalls

  • Unit mix-ups – Entering one side in feet and another in inches will give a meaningless result. Always convert to one unit first.
  • Triangle inequality violation – The sum of any two sides must be greater than the third side. If you enter sides like 1, 2, and 5, no real triangle exists. Heron’s formula will give a negative number under the square root, which is invalid. The calculator may show an error or a nonsensical value.
  • Confusing perimeter and area – Perimeter is one-dimensional (units), area is two-dimensional (square units). They are not interchangeable.
  • Rounding too early – If you compute the semi-perimeter and round it, then use that rounded value in Heron’s formula, your final area may be slightly off. The calculator keeps full precision internally.
  • Using the wrong formula – If you have a right triangle and know the two legs, you can use Area = ½ × leg1 × leg2, which is simpler. But if you only know the sides, Heron’s formula always works.

Limitations of Heron’s Formula

Heron’s formula is universal for triangles with known side lengths, but it has a few practical limitations:

  • It requires all three sides. If you know two sides and the included angle, you’d use Area = ½ × a × b × sin(C) instead.
  • It doesn’t give angles or heights. The formula only outputs area. For other properties, you’d need additional trigonometry.
  • Numerical stability for very skinny triangles. When a triangle is extremely thin (one side nearly equal to the sum of the other two), Heron’s formula can suffer from rounding errors in floating-point arithmetic. In practice, this rarely matters for everyday calculations.
  • It assumes a flat (Euclidean) triangle. On a curved surface like the Earth, the area calculation is different, but for any normal-sized plot, the error is negligible.

Frequently Asked Questions

Can I use this calculator for a right triangle?

Yes. Heron’s formula works for right triangles just as well as any other triangle. If you know the two legs (the sides forming the right angle), you can also use the simpler formula: Area = ½ × leg1 × leg2. But if you only know the three sides, this calculator gives the correct area.

What if I only know the base and height?

Then you don’t need Heron’s formula. Use Area = ½ × base × height. This is the most common formula taught in introductory geometry. You can still use this calculator by entering the base and height as two sides, but you’d also need a third side—which you might not have. In that case, use a dedicated base-height calculator.

Why does the calculator sometimes show an error?

The most likely reason is that the three side lengths you entered cannot form a triangle. Remember the triangle inequality: the sum of any two sides must be greater than the third. For example, sides of 1, 2, and 3 do not form a triangle because 1 + 2 is not greater than 3. Check your inputs and make sure they satisfy this rule.

What units should I use?

Any units you like, as long as all three sides use the same unit. The perimeter will be in that unit, and the area will be in that unit squared. For example, if you enter centimeters, the perimeter is in centimeters and the area in square centimeters. If you need square meters, convert all sides to meters first.

How do I convert the area to different units?

To convert between square units, use conversion factors. For example, 1 square meter = 10.7639 square feet, and 1 square foot = 144 square inches. If your calculator gives square feet and you need square yards, divide by 9 (since 1 yard = 3 feet, so 1 square yard = 9 square feet).

Is Heron’s formula exact?

Yes, Heron’s formula gives the exact area for a triangle with given side lengths, assuming perfect measurements. In practice, your side measurements have some error, so the area will inherit that uncertainty. The formula itself is mathematically precise.

Related

Formula used
in a | Side a | m | 5 | 0
in b | Side b | m | 6 | 0
in c | Side c | m | 7 | 0
out perimeter | Perimeter | m | a + b + c | 2
out area | Area | m² | sqrt((a+b+c)/2*((a+b+c)/2-a)*((a+b+c)/2-b)*((a+b+c)/2-c)) | 2

Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.