Perimeter Calculator

The perimeter is the total distance around a shape — the length of fence, edging or trim you would need.

Perimeter of a shape

Perimeter26

Working

  1. P = 2(l + w) = 2 × (8 + 5) = 26

Formulas

Area and perimeter formulas
ShapeAreaPerimeter
Square (side s)s²4s
Rectangle (l × w)l × w2(l + w)
Triangle½ × b × ha + b + c
Circle (radius r)πr²2πr
Ellipse (semi-axes a, b)πab≈ Ramanujan approximation
Trapezoid(a + b) ÷ 2 × ha + b + c + d
Parallelogramb × h2(a + b)
Rhombus (diagonals p, q)pq ÷ 24s
Sector (angle θ°)(θ ÷ 360) × πr²2r + (θ ÷ 360) × 2πr
Regular n-gon (side s)ns² ÷ (4 tan(180°/n))n × s

Worked example

A rectangular garden 8 m × 5 m

  1. P = 2 × (length + width)
  2. 2 × (8 + 5) = 2 × 13 = 26

26 m of fencing goes all the way round.

Circles and ellipses

A circle’s perimeter is called its circumference: C = 2πr = πd. An ellipse has no simple exact formula; this calculator uses Srinivasa Ramanujan’s second approximation, which is accurate to within a tiny fraction of a percent even for long, thin ellipses.