The area and perimeter calculator finds the area and perimeter (or circumference) of ten common shapes — rectangle, square, circle, triangle, right triangle, trapezoid, parallelogram, ellipse, regular polygon and circle sector. Enter the measurements in any unit and see the result with the formula used, plus extras like diagonals, hypotenuse and interior angles. It works in your browser.
| Shape | Area | Perimeter |
|---|---|---|
| Rectangle | l × w | 2(l + w) |
| Circle | πr² | 2πr |
| Triangle | √(s(s−a)(s−b)(s−c)) | a + b + c |
| Trapezoid | (a + b)h / 2 | a + b + c + d |
| Regular polygon | ns² / (4 tan(π/n)) | ns |
Use Heron's formula: find s = (a + b + c) ÷ 2, then area = √(s(s − a)(s − b)(s − c)).
They're the same idea — the distance around a shape. Circumference is the word used for circles.
Enter every measurement in the same unit; area comes out in that unit squared.
There's no exact simple formula, so Ramanujan's very accurate approximation is used.
No. It's calculated in your browser.
Each shape uses its standard formula: rectangle A = lw and P = 2(l + w) with the diagonal √(l² + w²); circle A = πr² and C = 2πr; triangles from three sides use Heron's formula A = √(s(s − a)(s − b)(s − c)) with s the semi-perimeter, and side lengths that can't form a triangle (one side at least the sum of the other two) are rejected; a right triangle also gives the hypotenuse; trapezoid A = (a + b)h ÷ 2; parallelogram A = bh; regular polygon A = ns² ÷ (4 tan(π/n)) with the interior angle (n − 2) × 180° ÷ n; a sector uses its angle as a fraction of 360°. An ellipse's area is πab, but its perimeter has no exact closed form, so Ramanujan's approximation π(3(a + b) − √((3a + b)(a + 3b))) is used, which is accurate to a few parts per million for most shapes. The formula is shown with every result.