POLYGON CALCULATOR

Regular polygon calculator

Enter the number of sides and a side length, get the rest.

ft

How do I find the interior angle of a regular polygon?

(n − 2) × 180° ÷ n. A hexagon has 120° angles, an octagon 135° and a pentagon 108°.

What do the interior angles add up to?

(n − 2) × 180°: 540° for a pentagon, 720° for a hexagon.

How do I find the area of a regular polygon?

Area = ½ × perimeter × apothem, where the apothem is the distance from the center to a side: s ÷ (2 tan(180° ÷ n)). A hexagon with 2-unit sides has an area of 6√3 ≈ 10.39.

How many diagonals does a polygon have?

n(n − 3) ÷ 2: 9 for a hexagon, 20 for an octagon.

What is the exterior angle?

360° ÷ n — the turn at each corner. The exterior angles of any polygon add up to 360°.

How do I find the side if I know the radius of the circle the polygon fits in?

Use s = 2R × sin(180° ÷ n), where R is the distance from the center to a corner. A regular pentagon with R = 10 has a side of 2 × 10 × sin 36° = 11.76; type that side into the calculator and the circumradius comes back as 10.00. For a hexagon the formula gives s = R, so its side equals the radius.

Does it work for irregular polygons?

No. Every side and every angle must be equal. A shape with equal sides but unequal angles, like a rhombus, does not follow these formulas. For any polygon whose corner coordinates you know, use the shoelace formula calculator for the area.

The formulas and what they assume

For n equal sides of length s, the interior angles add up to (n − 2) × 180° (Wolfram MathWorld, “Regular Polygon”), so each is (n − 2) × 180° ÷ n and each exterior angle is 360° ÷ n. The apothem, from the center to the middle of a side, is s ÷ (2 tan(180° ÷ n)); the circumradius, from the center to a corner, is s ÷ (2 sin(180° ÷ n)); and the area is ½ × apothem × perimeter, because the polygon splits into n triangles with base s and height equal to the apothem. The diagonal count n(n − 3) ÷ 2 follows from counting: each corner has n − 3 diagonals, and each diagonal has two ends. The calculator needs a whole number of sides from 3 to 1,000 and a side above zero.

Worked example: a regular pentagon

Take n = 5 and s = 10. Each interior angle is 3 × 180° ÷ 5 = 108°, each exterior angle is 72°, and the angles add up to 540°. The perimeter is 50, the apothem 6.882 and the circumradius 8.507. The area is ½ × 6.882 × 50 = 172.05, which agrees with the closed form (s² ÷ 4) × √(25 + 10√5) = 172.05 on MathWorld. There are 5 diagonals.

Common mistakes

The calculator wants the side, not the radius. Typing 10 as the side of a pentagon whose corners are 10 from the center gives 172.05, but the real side is 11.76 and the real area 237.76, about 28% more. On a pocket calculator, tan(180° ÷ n) must be taken in degree mode; with tan(36) read in radians the pentagon’s apothem comes out as 0.645 instead of 6.882. And do not confuse the two angles: for the pentagon 108° is the corner and 72° is the turn.

Sources: Wolfram MathWorld, “Regular Polygon” (apothem, circumradius, area and the pentagon’s closed form, angle sum). Related tools: shoelace formula calculator, triangle calculator, circle calculator and area calculator. How we check our calculators.