A regular polygon has all sides equal and all angles equal: the equilateral triangle, the square, the hexagon of a honeycomb cell, the octagon of a stop sign. Because the shape is so symmetric, the number of sides plus a single measurement determines everything else. This calculator accepts the side, circumradius, apothem, perimeter or area and returns the rest, along with the angles and the number of diagonals.
How to use the regular polygon calculator
- Enter the Number of sides (n), any whole number from 3 to 1,000.
- Under I know the, choose Side, Circumradius (center to a corner), Apothem (center to the middle of a side), Perimeter or Area.
- Type the measurement in Value and pick the Units. If you chose Area, enter it in square units.
- Read the shape name, side, perimeter, area, both radii, the interior, exterior and central angles, the sum of the interior angles and the number of diagonals. The steps show which formula produced each value.
Regular polygon formulas
Draw lines from the center to every corner and the polygon splits into n identical isosceles triangles. Each has a base s, a height equal to the apothem r and an apex angle of 360° ÷ n. Halving one of them gives a right triangle with an angle of 180° ÷ n at the center, and the rest is trigonometry:
The area formula ½ × P × r is the sum of the n triangles, each with area ½ × s × r. The same formula gives the area of a circle if you let the perimeter become 2πR and the apothem become R.
Worked example: a stop sign
A standard 30-inch stop sign is a regular octagon measured across the flats, so its apothem is 15 in. Enter n = 8, choose Apothem and type 15 with inches as the unit.
- Side: 2 × 15 × tan 22.5° = 12.43 in
- Perimeter: 8 × 12.43 = 99.41 in
- Circumradius: 16.24 in, so the sign is about 32.47 in across the corners
- Area: ½ × 99.41 × 15 = 745.58 in², about 5.18 ft² of sheeting
- Interior angle 135°, sum of interior angles 1,080°, and 20 diagonals
Angles and area factors for 3 to 12 sides
Multiply the area factor by the side squared to get the area, and multiply the radius ratios by the side to get R and r.
| n | Name | Interior angle | Area ÷ s² | R ÷ s | r ÷ s |
|---|---|---|---|---|---|
| 3 | Equilateral triangle | 60° | 0.4330 | 0.5774 | 0.2887 |
| 4 | Square | 90° | 1.0000 | 0.7071 | 0.5000 |
| 5 | Pentagon | 108° | 1.7205 | 0.8507 | 0.6882 |
| 6 | Hexagon | 120° | 2.5981 | 1.0000 | 0.8660 |
| 7 | Heptagon | 128.57° | 3.6339 | 1.1524 | 1.0383 |
| 8 | Octagon | 135° | 4.8284 | 1.3066 | 1.2071 |
| 9 | Nonagon | 140° | 6.1818 | 1.4619 | 1.3737 |
| 10 | Decagon | 144° | 7.6942 | 1.6180 | 1.5388 |
| 11 | Hendecagon | 147.27° | 9.3656 | 1.7747 | 1.7028 |
| 12 | Dodecagon | 150° | 11.1962 | 1.9319 | 1.8660 |
A few patterns stand out. In a hexagon the circumradius equals the side, because the six center triangles are all equilateral. In a decagon R ÷ s is 1.6180, the golden ratio. And only the triangle, square and hexagon have interior angles that divide 360° evenly, which is why they are the only regular polygons that tile a floor with no gaps. Bees, bathroom tile and paving stones all take advantage of that.
Practical tips
- Nuts and bolts are sized across the flats, so a hex nut’s wrench size is twice its apothem.
- Gazebos and octagonal decks are often specified by the overall width. Check whether the plan means flat to flat or corner to corner; for an octagon the two differ by about 8%.
- Cutting miters: each corner joint of a picture frame or planter with n sides is cut at half the exterior angle, 180° ÷ n. That is 22.5° for an octagon and 30° for a hexagon.
Archimedes used the same formulas around 250 BC, squeezing a circle between inscribed and circumscribed 96-sided polygons to prove that π lies between 3 10⁄71 and 3 1⁄7. For a circle itself, use the circle calculator.
Frequently asked questions
What is an apothem?
The apothem is the distance from the center of a regular polygon to the midpoint of a side, meeting that side at a right angle. It is also the radius of the largest circle that fits inside the polygon, which is why the calculator labels it the inradius. A hexagon with 4 cm sides has an apothem of about 3.464 cm.
How do I find the interior angle of a regular polygon?
Use (n − 2) × 180° ÷ n. A pentagon has interior angles of 108°, a hexagon 120° and an octagon 135°. The exterior angle is 360° ÷ n, and an interior and exterior angle always add up to 180°.
How many diagonals does a polygon have?
A polygon with n sides has n(n − 3) ÷ 2 diagonals. Each corner connects to every other corner except itself and its two neighbors, and each diagonal gets counted from both ends. A hexagon has 9 diagonals and a dodecagon has 54.
Should I measure a hexagon across the flats or across the corners?
Either works if you pick the matching option. The distance across the flats, side to side, is twice the apothem; the distance across the corners is twice the circumradius. Halve your measurement and enter it as the apothem or the circumradius.
Why does a polygon with many sides look like a circle?
The area equals half the perimeter times the apothem. As n grows, the perimeter approaches the circumference and the apothem approaches the radius, so the area approaches πR². A 1,000-sided polygon with a circumradius of 1 has an area of 3.141572, within 0.001% of π.