Octagon Calculator
Result
Area
- Perimeter
- 48.0000 cm
- Apothem
- 7.2426 cm
- Short diagonal
- 11.0866 cm
- Medium diagonal
- 14.4853 cm
- Long diagonal
- 15.6788 cm
- Interior angle
- 135 °
An octagon calculator takes the side length of a regular octagon and returns seven measurements: the area, the perimeter, the apothem, the three diagonals, and the interior angle. Eight sides is where a regular polygon stops being a shape you can work out in your head and starts being one you look up, and the octagon is the first of them that turns up in ordinary life. Stop signs, octagonal tiles, gazebo roofs, spa covers, trampoline mats and the ends of a bolt are all octagons, and the reason is nearly always the same: an octagon is the shape you get by cutting the corners off a square, so it keeps the flat sides and right angles of a square while removing the four corners that were catching on things. That is also why it packs the way it does — octagons tile a floor only if you fill the small square gaps between them, which is exactly the pattern of an octagonal tiling with square inserts. The arithmetic follows from the sides. The perimeter is eight sides. The interior angle of a regular polygon is fixed by the side count alone, and for eight of them it is 135 degrees, which is the number to remember about an octagon because it is what makes the shape cuttable: a mitre saw set to 67.5 degrees — half of 135 — is what joins two octagon edges, and a picture frame of eight pieces uses exactly that setting. The area is the square root expression two times one plus the square root of two, times the side squared, and it is worth knowing that this constant is about 4.83, so an octagon of side one covers 4.83 square units against the 1 of a square of the same side. The apothem, the distance from the centre straight out to the middle of a side, is the side times one plus the square root of two, halved. And the octagon has three diagonals rather than the two a hexagon has, because with eight corners there are three distinct distances you can span: the short one that skips one corner, the middle one that skips two, and the long one that goes straight across. The middle diagonal is exactly twice the apothem, which is not a coincidence — both come from the same expression, one halved and one not — and the long one is the diameter of the circle drawn around the octagon.
Regular octagons from a side of zero to a side of ten
| Side (cm) | Area (cm²) | Perimeter (cm) | Apothem (cm) | Short diagonal (cm) | Medium diagonal (cm) | Long diagonal (cm) | Interior angle (°) |
|---|---|---|---|---|---|---|---|
| 6 | 173.8234 | 48 | 7.2426 | 11.0866 | 14.4853 | 15.6788 | 135 |
| 1 | 4.8284 | 8 | 1.2071 | 1.8478 | 2.4142 | 2.6131 | 135 |
| 2 | 19.3137 | 16 | 2.4142 | 3.6955 | 4.8284 | 5.2263 | 135 |
| 3 | 43.4558 | 24 | 3.6213 | 5.5433 | 7.2426 | 7.8394 | 135 |
| 5 | 120.7107 | 40 | 6.0355 | 9.2388 | 12.0711 | 13.0656 | 135 |
| 7.5 | 271.599 | 60 | 9.0533 | 13.8582 | 18.1066 | 19.5984 | 135 |
| 10 | 482.8427 | 80 | 12.0711 | 18.4776 | 24.1421 | 26.1313 | 135 |
| 0 | 0 | 0 | 0 | 0 | 0 | 0 | 135 |
Eight octagons, and the first row is the one the page loads with. The last column is the same number on every row, 135, and that is the point of it rather than a copy-and-paste error: the interior angle of a regular octagon is fixed by having eight sides, so it does not move when the size does, and it is the one figure on the page that survives the side going to zero. The two columns to read together are the apothem and the medium diagonal, which are in a fixed 1-to-2 relationship on every single row — 1.2071 against 2.4142, 6.0355 against 12.0711, 12.0711 against 24.1421 — because both come from the same expression, one divided by two and one not. That is the cheapest check on the whole table: if any row's middle diagonal is not exactly twice its apothem, the row is wrong. The seventh column, the long diagonal, answers a second question that the label does not mention: it is the diameter of the circle drawn around the octagon, so every row also tells you what round blank the octagon came out of. One pair of cells repeats digits across two rows in a way that looks like a mistake and is not: the medium diagonal at a side of 5 is 12.0711, and so is the apothem at a side of 10. That is a consequence of the doubling rule rather than a coincidence — doubling the side doubles every length in the list, so the apothem of the larger octagon has to land on some length belonging to the smaller one, and here it is the middle diagonal. The first row is also the row that lines up with the two other polygon pages at a side of 6: 173.8234 here, against 93.5307 for the hexagon and 61.9372 for the pentagon, so the same edge buys more area the more sides there are. Every number here is recomputed from its side when the page is built, in centimetres and degrees, and the decimal widths are the same ones the results panel uses.
Formula
A = 2(1 + √2) × s² P = 8s a = s(1 + √2) ÷ 2 d_short = s√(2 + √2) d_medium = s(1 + √2) d_long = s√(4 + 2√2) interior angle = 135°
- Side
- The length of any one of the eight sides, in centimetres. As with every regular polygon this is the only input there is, because all eight sides are equal and all eight angles are fixed at 135 degrees, so this one number decides the size of the whole shape
- Area
- The space the octagon covers, in square centimetres: two times one plus the square root of two, times the side squared. The constant is about 4.828, which is the figure to carry around — an octagon covers nearly five times the area of the square drawn on one of its sides
- Perimeter
- The distance all the way around, in centimetres: eight times the side, since all eight are the same. It is the one output that is always exact whenever the side is, which makes it the figure to check the others against when a result looks wrong
- Apothem
- The distance from the centre straight out to the midpoint of a side, in centimetres, which is the side times one plus the square root of two, halved. It is the radius of the largest circle that fits inside the octagon, and it is the figure that sets how far apart the flat sides are — twice the apothem is the octagon measured across its flats
- Short diagonal
- The distance between two corners with one corner between them, in centimetres, which is the side times the square root of two plus the square root of two. It is a little shorter than the middle diagonal and a little longer than the side, and on an octagon it is close enough to the side that the two are easy to mistake for each other in a drawing
- Medium diagonal
- The distance between two corners with two corners between them, in centimetres: the side times one plus the square root of two. It is exactly twice the apothem, because both are the same expression with a two in a different place, and it is the diagonal a regular octagon's own geometry is built around
- Long diagonal
- The distance from one corner straight through the centre to the opposite corner, in centimetres, which is the side times the square root of four plus two times the square root of two. It is the widest measurement you can take across the shape and it is also the diameter of the circle drawn around the octagon, so halving it gives the radius that circle is drawn with
- Interior angle
- The angle between two neighbouring sides, inside the octagon: 135 degrees, and fixed there by the side count alone. It does not depend on the side length at all, which is why this column of the reference table is the same number on every row — an octagon of side 1 and an octagon of side 10 have the same interior angle, and only their sizes differ
- √2
- The square root of two, about 1.4142136. It appears in every one of the seven outputs except the perimeter and the interior angle, and it is there because the octagon is the square with its corners cut off — cutting a corner at 45 degrees is exactly where the square root of two comes from
The page is for the octagon as a physical object, and the two commonest cases are a flat piece and a round fitting. If you are cutting an octagon out of a sheet — a table top, a tile, a paving slab, the end plate of a post — the area tells you what you are using and the apothem tells you how to lay it out. The apothem is the number to mark first: twice it is the width across the flats, and the flats are what you measure a cut octagon by, since the corners are awkward to get a rule across. The long diagonal then gives the width across the corners, which is what determines whether the finished piece fits inside the circle you are cutting it from; that same figure is the diameter of the octagon's circumscribed circle, so a round blank of that diameter will contain the octagon with nothing to spare. If you are making something join eight pieces — a frame, a lantern, a gazebo roof — the interior angle of 135 degrees is the figure to reach for, because the mitre on each piece is half of it, 67.5 degrees, and that setting is the same for every octagon whatever its size. If the round fitting is the case, the long diagonal is the answer to whether the octagon will pass through a circular opening, and the apothem is the answer to how much flat surface it presents once it is there. And if what you want is simply to compare an octagon against a square of the same side, the area constant of 4.83 against the square's 1 is the whole of the comparison: the octagon covers more ground for the same edge, but it also has twice as many edges, so the perimeter column is the fairer figure when it is material you are buying.
Worked examples
A side of 6
- Perimeter: 8 × 6 = 48
- Apothem: 6 × (1 + √2) ÷ 2 = 7.242640…, which rounds to 7.2426
- Medium diagonal: 6 × (1 + √2) = 14.485281…, which rounds to 14.4853
- Short diagonal: 6 × √(2 + √2) = 11.086554…, which rounds to 11.0866
- Long diagonal: 6 × √(4 + 2√2) = 15.678754…, which rounds to 15.6788
- Area: 2 × (1 + √2) × 36 = 173.823376…, which rounds to 173.8234
- Interior angle: (8 − 2) × 180 ÷ 8 = 135, exact
The input the page loads with. Two checks are visible in this one row. The medium diagonal, 14.4853, is exactly twice the apothem, 7.2426 — that holds on every side, not just this one, because both come from the same expression with a two in a different place. And the long diagonal of 15.6788 is the diameter of the circle drawn around the octagon, so an octagon of side 6 fits inside a circle of diameter 15.6788 centimetres and no smaller. This is also the row that compares with the two neighbouring pages at the same side length: a side of 6 gives 173.8234 here, 93.5307 on the hexagon page and 61.9372 on the pentagon page — the same edge, and more of it enclosed the more sides there are.
A side of 1
- Perimeter: 8 × 1 = 8
- Apothem: (1 + √2) ÷ 2 = 1.207106…, which rounds to 1.2071
- Medium diagonal: 1 + √2 = 2.414213…, which rounds to 2.4142
- Short diagonal: √(2 + √2) = 1.847759…, which rounds to 1.8478
- Long diagonal: √(4 + 2√2) = 2.613125…, which rounds to 2.6131
- Area: 2 × (1 + √2) = 4.828427…, which rounds to 4.8284
- Interior angle: 135
The unit octagon, and the row that shows the two constants most plainly: the area is 4.8284 and the medium diagonal is 2.4142, which is the same number halved. The short diagonal of 1.8478 is worth pausing on, because it is the diagonal that skips one corner and it is less than twice the side — an octagon's corners are close together compared with a hexagon's, which is what makes the shape look almost round. Against a square of side one, whose area is 1, the octagon covers 4.83 times as much ground.
A side of 5
- Perimeter: 8 × 5 = 40
- Apothem: 5 × (1 + √2) ÷ 2 = 6.035533…, which rounds to 6.0355
- Medium diagonal: 5 × (1 + √2) = 12.071067…, which rounds to 12.0711
- Short diagonal: 5 × √(2 + √2) = 9.238795…, which rounds to 9.2388
- Long diagonal: 5 × √(4 + 2√2) = 13.065628…, which rounds to 13.0656
- Area: 2 × (1 + √2) × 25 = 120.710678…, which rounds to 120.7107
- Interior angle: 135
A five-centimetre octagon, about the size of a small tile or the end of a fence post. It is the row that lines up with another row of this same table in a way that looks like a mistake: the medium diagonal here, 12.0711, is the same four digits as the apothem at a side of 10. That is because doubling the side doubles every length in this list, so any value the apothem takes at side 10 must appear somewhere at side 5 — here, as the diagonal that is exactly twice the apothem of the smaller octagon. Nothing is computed twice.
A side of 10
- Perimeter: 8 × 10 = 80
- Apothem: 10 × (1 + √2) ÷ 2 = 12.071067…, which rounds to 12.0711
- Medium diagonal: 10 × (1 + √2) = 24.142135…, which rounds to 24.1421
- Short diagonal: 10 × √(2 + √2) = 18.477590…, which rounds to 18.4776
- Long diagonal: 10 × √(4 + 2√2) = 26.131259…, which rounds to 26.1313
- Area: 2 × (1 + √2) × 100 = 482.842712…, which rounds to 482.8427
- Interior angle: 135
A ten-centimetre octagon, which is a common size for a paving slab or a decorative tile. The apothem of 12.0711 is the figure to lay it out with: twice it, 24.1421, is the width across the flats, and that is the distance you mark out on the bench. The long diagonal of 26.1313 is the width across the corners, so a circular hole of that diameter is the smallest one this octagon will drop through. Compare the two widths — 24.14 across the flats against 26.13 across the corners — and you have the octagon in one line: the corners stick out about 8 per cent beyond the flats, which is the whole of what cutting them off a square accomplished.
A side of 0
- Perimeter: 8 × 0 = 0
- Apothem: 0 × (1 + √2) ÷ 2 = 0
- Medium diagonal: 0 × (1 + √2) = 0
- Short diagonal: 0 × √(2 + √2) = 0
- Long diagonal: 0 × √(4 + 2√2) = 0
- Area: 2 × (1 + √2) × 0 = 0
- Interior angle: (8 − 2) × 180 ÷ 8 = 135
Zero is a legal input rather than an empty box, and this row is the plainest demonstration of what the interior angle is: an octagon of side zero has collapsed to a point, six of the seven figures are zero, and the interior angle is still 135 degrees. It is a property of the shape and not of the size, so it survives the size going away entirely. Leaving the box blank is the different case: with nothing in it the page shows no result at all.
Limitations
The page is for regular octagons only: all eight sides the same length and all eight angles 135 degrees. An octagon that is not regular — a square with unequal corners cut off, for instance, or an elongated one — has no single side length and cannot be described by one number, and the page will quietly give you the regular octagon with that side rather than telling you that the shape you have in mind is a different one. The outputs are in centimetres and square centimetres whatever the unit dropdown is set to, so a side entered in inches comes back as a centimetre answer you have to convert yourself. Four decimal places is a display width rather than a claim about precision, and it is generous for a measured side; the last two digits are not meaningful unless the input was exact. The interior angle is exact at 135 degrees and prints without decimals for that reason, but it is the same number on every row, so a page that appears not to respond to a change of side has not frozen — six of the seven figures moved. The page is two-dimensional and has no field for material thickness, so it cannot give the volume of an octagonal prism, the weight of an octagonal plate, or the depth of an octagonal hole. It also does not model the square inserts that fill the gaps when octagons are tiled together, which is a layout question rather than a measurement of one shape.
Frequently asked questions
- Why does the interior angle never change when I change the side?
- Because a regular octagon's angles are fixed by the number of sides and nothing else. The interior angle of a regular polygon is the side count minus two, times 180 degrees, divided by the side count; for eight sides that is 135 degrees, and no side length appears anywhere in that expression. An octagon of side 1 and an octagon of side 100 have exactly the same angles and differ only in size. It is why the last column of the reference table is the same number on every row, and it is what makes a mitre setting of 67.5 degrees work for every octagon you will ever cut.
- Which of the three diagonals is which?
- The short diagonal skips one corner and is the side times the square root of two plus the square root of two, at 1.85 for a unit side. The medium diagonal skips two corners and is the side times one plus the square root of two, at 2.41. The long diagonal runs straight through the centre and is the side times the square root of four plus two times the square root of two, at 2.61. A hexagon has only two of these because with six corners there are only two distinct spans; eight corners give three. The middle one is exactly twice the apothem, which is the quickest way to tell it apart from the others.
- What is the apothem and why does it matter for an octagon?
- It is the distance from the centre straight out to the middle of a side, and it is the radius of the largest circle that fits inside. For an octagon it matters more than for most shapes because the flats are what you measure the finished piece by: twice the apothem is the width across the flats, and unlike the corners the flats are easy to get a rule across. If you are marking out a cut octagon, the apothem is the first number to put on the work.
- How much bigger is an octagon than a square of the same side?
- About 4.83 times the area, since a unit octagon covers 4.8284 square units and a unit square covers 1. That number is the whole story of the shape: an octagon is a square with its four corners cut off, and cutting the corners removes area from the square while leaving the four flats almost the full width. But the octagon also has eight edges rather than four, so if it is edging or frame material you are buying, compare perimeters rather than areas.
- What is the smallest round hole an octagon will pass through?
- A circle whose diameter equals the long diagonal, since that is the widest measurement across the shape and it runs corner to corner through the centre. For a side of 10 that is 26.1313 centimetres. The same figure read the other way round is the diameter of the circle the octagon fits inside exactly, with all eight corners touching it, which is the useful one when you are cutting the octagon out of a round blank and want to waste as little as possible.
- Does the octagon tile a floor on its own?
- No, and the gaps are the interesting part. Octagons laid flat leave a small square hole between every four of them, and those squares are exactly why octagonal tiling works as a pattern — the classic octagon-and-square floor is the octagons doing the covering and the squares filling in. The page measures one octagon and does not model the layout, so the number of tiles you need for a floor is a separate calculation from the ones shown here.
References
- Octagon — the eight-sided polygon, with the area, the apothem, the three diagonals and the interior angle this page computes, and the construction as a square with its corners cut off — Wolfram MathWorld (United States)
- Regular polygon — the family a regular octagon belongs to, with the interior angle fixed by the side count and the apothem defined as the distance from the centre to a side, which is what makes the middle diagonal exactly twice it — Wolfram MathWorld (United States)
- Apothem — the distance from the centre of a regular polygon to the midpoint of a side, which is the radius of the inscribed circle and, doubled, the width of this shape across its flats — Wolfram MathWorld (United States)
- 教育部关于印发义务教育课程方案和课程标准(2022 年版)的通知——The fifth item in the annex list of this notice is the Mathematics Curriculum Standards for Compulsory Education (2022 edition); the sides, perimeter and area of a regular polygon are part of the compulsory-education mathematics curriculum, and the wording of the standards and the grade-band breakdown are governed by that annex — 中华人民共和国教育部