MATH · GEOMETRY

Octagon calculator

Explore the geometry of a regular octagon: area, perimeter, three diagonal lengths, circumradius and inradius — all updated live from one known measurement.

Report error
Area
—
2(1 + √2) a²
Perimeter
—
8a
Long diagonal
—
a√(4 + 2√2)

Area growth as the side changes

The curve updates with your current side length. The green point marks your value.
Live
Interactive relationshipCurrent a: —Current A: —

Side, diagonals and radii

All lengths are shown against the same scale so their ratios are easy to compare.
Live
Updates with every inputGreen bars = current geometry

Live octagon intelligence

Live
Interior angle135°
Central angle45°
Diagonal count20 total

Regular octagon dimensions

Live values
MeasureFormulaCurrent value
Enter one known value and the calculator will derive the complete regular-octagon geometry.
THE CONCEPT

What is a regular octagon?

An octagon is a polygon with eight sides and eight vertices. In this calculator, we work with the regular octagon: all eight sides have the same length and all eight interior angles are equal. Once one length is known, the entire shape is determined by geometry.

That distinction matters. A general octagon can have unequal sides and unequal angles, so one side length is not enough to determine its area. A regular octagon is different because symmetry fixes the relationships between side, area, perimeter, diagonals, circumradius and inradius.

side a R = circumradius r = apothem O 8 equal sides 8 equal angles
PropertyRegular octagonWhy it matters
Sides8 equal sidesOne side length determines the scale of the whole shape.
Interior angles135° eachThe shape closes with eight identical corners.
Central angle45°360° is divided equally among 8 sectors.
Symmetry8-fold rotational symmetryA 45° rotation maps the regular octagon onto itself.
Diagonals20 totalThey form three distinct length classes.
FORMULAS

Every important octagon formula, explained

Let a be the side length. The formulas below are not isolated facts: they are connected through the same 45° central geometry.

Area

A = 2(1 + √2)a²

Use this when the side is known. Because of a², scaling the side changes area quadratically.

Perimeter

P = 8a

Eight equal sides are simply added together.

Long diagonal

d = a√(4 + 2√2)

It joins opposite vertices and passes through the center.

Medium diagonal

m = a(1 + √2)

It is also the distance across opposite parallel sides, so m = 2r.

Short diagonal

s = a√(2 + √2)

Its endpoints have one vertex between them.

Radii

R = d/2   ·   r = m/2

R reaches a vertex; r reaches the midpoint of a side at a right angle.

Why does the area formula work?

Draw lines from the center to all eight vertices. The octagon becomes 8 congruent isosceles triangles. Each triangle has base a and height r, so its area is a·r/2. Multiplying by eight gives:

A = 8 × (a·r/2) = 4ar   and because   P = 8a,   A = P·r/2.

For a regular octagon, r = a(1 + √2)/2. Substituting that into 4ar gives A = 2(1 + √2)a². This is useful because it explains the formula instead of asking you to memorize it.

Useful inverse formulas

If you knowFind the side aThen calculate
Perimeter Pa = P/8Area, diagonals and radii
Area Aa = √[A / (2(1 + √2))]All remaining properties
Long diagonal da = d / √(4 + 2√2)Area, perimeter and radii
Medium diagonal ma = m / (1 + √2)Area and perimeter
Short diagonal sa = s / √(2 + √2)Area and perimeter
Circumradius Ra = 2R sin(22.5°)Area, perimeter and diagonals
Inradius ra = 2r tan(22.5°)Area, perimeter and diagonals
EXAMPLES

Worked examples, step by step

Example 1 — side length 5 cm

Suppose the side is a = 5 cm. Start with the perimeter and area, then use the diagonal and radius relationships.

StepCalculationResult
1 · PerimeterP = 8 × 540 cm
2 · Area2(1 + √2) × 5²120.711 cm²
3 · Long diagonal5√(4 + 2√2)13.066 cm
4 · Medium diagonal5(1 + √2)12.071 cm
5 · Short diagonal5√(2 + √2)9.239 cm
6 · Circumradius13.066 / 26.533 cm
7 · Inradius12.071 / 26.036 cm

Example 2 — area is known

Suppose a drawing gives A = 200 cm², but the side is missing. Rearrange the area formula rather than guessing:

a = √[200 / (2(1 + √2))] ≈ 6.277 cm

Now that a is known, the calculator can derive the perimeter, three diagonal classes and both radii from that single recovered side length.

Example 3 — perimeter is known

If P = 40 cm, the quickest route is a = P/8 = 5 cm. Notice how this immediately returns the same values as Example 1. This is a useful self-check when working from a technical drawing.

01 · KNOWN
One measurementSide, area, perimeter, diagonal or radius
02 · CONVERT
Recover aUse the matching inverse formula
03 · DERIVE
Everything elseArea, P, diagonals, R and r
GEOMETRY

Where do 45°, 22.5° and √2 come from?

A full turn around the center is 360°. Because a regular octagon has eight identical sectors, each central angle is 360°/8 = 45°. Draw the radius to the midpoint of one side and the 45° triangle is split into two right triangles, each with an angle of 22.5°.

45° O 22.5° half of a central angle

Using right-triangle trigonometry gives the general regular-polygon relationships r = a/[2 tan(π/8)] and R = a/[2 sin(π/8)]. For the octagon, those expressions simplify to the familiar formulas containing √2.

A second way to understand the area

Imagine a square surrounding the regular octagon. Four identical right triangles are removed from its corners. This construction is especially useful when drawing or fabricating an octagon from a square, because it explains why the octagon has four pairs of parallel sides and why its corners are cut at equal geometry.

DIAGONALS & RADII

How the 20 diagonals are organized

A polygon with n vertices has n(n − 3)/2 diagonals. For an octagon this gives 8 × 5 / 2 = 20. Those 20 segments are not all different: in a regular octagon they fall into three length classes.

TypeWhat it connectsFormulaUseful relationship
ShortVertices with one vertex between thems = a√(2 + √2)Shortest diagonal
MediumVertices with two vertices between themm = a(1 + √2)m = 2r
LongOpposite verticesd = a√(4 + 2√2)d = 2R

The long diagonal is especially important: it passes through the center and is therefore the diameter of the circumcircle. The medium diagonal corresponds to the distance across opposite parallel sides, so it is twice the apothem.

Circumradius vs. inradius

🔵 Circumradius R

R = d/2

Distance from the center to any vertex. The circumcircle touches all eight vertices.

🟢 Inradius r

r = m/2

Distance from the center perpendicular to a side. The incircle touches all eight sides.

APPLICATIONS

How octagon measurements are used in practice

Different projects start with different measurements. A tile maker may know the side length, a drawing may specify the distance across flats, and a circular layout may give a radius. Knowing which measurement you have prevents using the wrong formula.

SituationLikely known measurementUseful result
Tile or tabletopSide or across-flats distanceArea for material planning
Frame or panelPerimeter or sideTotal edge length
Circular layoutCircumradius or diameterSide and diagonal lengths
Technical drawingOne diagonalRecover side, area and radii
Geometry exerciseSide, area or radiusPractice inverse formulas and symmetry
tile / floor plan circle + octagon 8 sidespanel / frame
COMMON MISTAKES

Five mistakes to avoid

  1. Confusing any octagon with a regular octagon. The formulas on this page assume all eight sides and angles are equal.
  2. Using a² incorrectly. Area uses the square of the side, so the unit becomes cm², m², in², and so on.
  3. Calling every diagonal the same. A regular octagon has short, medium and long diagonals.
  4. Mixing R and r. R goes to a vertex; r goes perpendicularly to a side.
  5. Forgetting the scale effect. If the side doubles, perimeter doubles but area becomes four times as large.
Teacher's shortcut: remember the chain a → P = 8a → r = a(1 + √2)/2 → A = P·r/2. From the same side length, the diagonal formulas complete the rest of the geometry.
FAQ

Octagon questions, answered clearly

How many sides does an octagon have?
Eight. An octagon has eight sides and eight vertices. The formulas on this page specifically describe a regular octagon unless stated otherwise.
What is the interior angle of a regular octagon?
Each interior angle is 135°. The eight interior angles add to 1080°.
What is the central angle?
The central angle between adjacent vertices is 45°, because 360° is divided into eight equal sectors.
What is the formula for the area of a regular octagon?
A = 2(1 + √2)a². An equivalent and more general formula is A = P·r/2, where r is the apothem.
What is the perimeter of an octagon?
For a regular octagon, P = 8a, where a is the side length.
How many diagonals does an octagon have?
20 diagonals in total. In a regular octagon, they form three length classes: short, medium and long.
What is the difference between circumradius and inradius?
The circumradius R is the distance from the center to a vertex. The inradius r, or apothem, is the perpendicular distance from the center to a side.
What is the distance across flats?
For a regular octagon, the distance between opposite parallel sides equals the medium diagonal and therefore equals 2r.
Can I calculate an octagon from its area or perimeter instead of its side?
Yes. The calculator accepts area, perimeter, all three diagonal classes, circumradius and inradius as known values and derives the side first.
Does doubling the side double the area?
No. Perimeter and every length scale by 2, but area scales by 2² = 4. This follows directly from the a² term in the area formula.