Skip to content
Calculator.hair

Polygon Calculator

Regular Polygon Calculator

Press Calculate to see the results.

Area of an Irregular Polygon From Coordinates

List the corners in order around the shape, one "x, y" pair per line. The shoelace formula then gives the enclosed area, and the edge lengths give the perimeter.

One point per line, in clockwise or counterclockwise order.

Press Calculate to see the results.

Enter how many sides a regular polygon has and any one of its measurements, and this polygon calculator works out the rest: side length, area, perimeter, apothem, circumradius, angles and number of diagonals. For an irregular polygon, use the coordinate tool below.

What Is a Regular Polygon?

A polygon is a closed flat shape made of straight sides. It is regular when all its sides are the same length and all its interior angles are equal, like an equilateral triangle, a square or the hexagonal cells of a honeycomb. Every regular polygon fits exactly inside a circle that passes through all its corners, the circumscribed circle, and around a circle that touches the middle of every side, the inscribed circle.

Because of that symmetry, a regular polygon is fixed by just two numbers: how many sides it has and any one length. That is why the calculator needs only n and one known measure.

How to Use the Polygon Calculator

Enter the number of sides, choose which measurement you know, and type its value. The known measure can be the side length, the circumradius (center to a corner), the apothem (center to the middle of a side), the area or the perimeter. All lengths come out in the same unit you used, and the area in that unit squared.

If the shape is not regular, switch to the irregular polygon tool and enter the coordinates of its corners in order. That works for any simple polygon, convex or not, such as a plot of land surveyed by its corner points.

Area of a Regular Polygon Formula

Joining the center to every corner cuts a regular polygon into n identical isosceles triangles. Each one has a base of s and a height equal to the apothem r, so its area is ½ × s × r, and the whole polygon has area ½ × n × s × r, or half the perimeter times the apothem. The apothem formula, r = s ÷ (2 tan(180°/n)), comes from the right triangle formed by the center, a corner and the midpoint of a side, whose angle at the center is 180°/n.

Worked example with the defaults, a regular hexagon with side 4. The perimeter is 6 × 4 = 24. The apothem is 4 ÷ (2 tan 30°) = 2√3 ≈ 3.4641. The area is ½ × 24 × 3.4641 ≈ 41.5692, the same as 3√3 ÷ 2 × 4². The circumradius is 4 ÷ (2 sin 30°) = 4, which is why a hexagon splits into six equilateral triangles.

A = n s² ÷ (4 tan(180°/n)) = ½ × P × r

n
the number of sides
s
the side length
P
the perimeter, n × s
r
the apothem, s ÷ (2 tan(180°/n))
R
the circumradius, s ÷ (2 sin(180°/n))

Pentagons, Hexagons and Other Common Polygons

Putting n into the general formula gives a shortcut for each shape. The area of a pentagon formula is A ≈ 1.7205 s², or exactly ¼√(5(5 + 2√5)) s². A hexagon is 3√3/2 s² ≈ 2.5981 s², and an octagon is 2(1 + √2) s² ≈ 4.8284 s². The interior angle is (n − 2) × 180° ÷ n, and each corner joins to n − 3 others by diagonals, for n(n − 3) ÷ 2 diagonals in all.

SidesNameInterior angleArea for side 1Diagonals
3Triangle60°0.43300
4Square90°12
5Pentagon108°1.72055
6Hexagon120°2.59819
8Octagon135°4.828420
10Decagon144°7.694235
12Dodecagon150°11.196254

Area of an Irregular Polygon

An irregular polygon has no single formula based on its sides, because the same side lengths can enclose different areas as the angles change. The area of an irregular polygon formula that works from coordinates is the shoelace formula: list the vertices in order, add up xᵢyᵢ₊₁ − xᵢ₊₁yᵢ for every edge, and take half the absolute value. The name comes from the criss-cross pattern of the multiplications.

For the default points (0, 0), (4, 0), (5, 3), (2, 5) and (−1, 3) the edge terms are 0, 12, 19, 11 and 0. They sum to 42, so the area is 21 square units. The points must go around the outline in order; if two edges cross, the formula subtracts part of the area, and the calculator warns you.

Frequently asked questions

What is the apothem of a polygon?

It is the distance from the center of a regular polygon to the midpoint of any side, and it meets that side at a right angle. It equals the radius of the inscribed circle: r = s ÷ (2 tan(180°/n)).

How do I find the area of a regular hexagon?

Multiply the square of the side by 3√3 ÷ 2, about 2.598. A hexagon with side 4 has area 2.598 × 16 ≈ 41.57.

What is the area of a regular polygon formula?

A = ½ × perimeter × apothem, which is the same as n s² ÷ (4 tan(180°/n)) when written in terms of the side length.

How do I find the area of an irregular polygon?

Either split it into triangles and rectangles and add their areas, or enter the corner coordinates into the shoelace tool on this page.

How many diagonals does a polygon have?

n(n − 3) ÷ 2. A pentagon has 5, a hexagon 9 and a decagon 35.

What happens as the number of sides grows?

The polygon gets closer to its circumscribed circle. At 100 sides its area is about 99.93% of the circle's, and the perimeter approaches 2πR.

Updated by Calculator.hair. How we build and check our calculators