Shape Perimeter Calculator – Regular, L-Shaped & Irregular Shapes

Perimeter is the distance around the outside of a shape, and it is the number you need for fencing, edging, trim, framing and anything else that follows a boundary. A shape perimeter calculator covers the shapes people meet most often: rectangles, squares, triangles, circles, semicircles, sectors, L-shapes and regular polygons, plus any irregular outline entered as corner coordinates.

Shape Calculators

Shape Perimeter Calculator

Perimeter of a rectangle, square, triangle, circle, semicircle, sector, L-shape, regular polygon or any irregular shape from coordinates.

Perimeter is a length, measured in feet, meters or similar linear units, while area is measured in square units. Two shapes can share the same area and have very different perimeters, so each needs its own calculation.

Perimeter formulas used by the calculator

Shape Perimeter Inputs
Rectangle P = 2(l + w) length, width
Square P = 4a side
Triangle P = a + b + c three sides
Circle C = 2πr radius
Semicircle P = πr + 2r radius
Sector P = rθ + 2r radius, angle
L-shape P = 2(W + H) overall width and height
Regular polygon P = n × s sides, side length
Irregular shape sum of distances between corners corner coordinates

Where l and w are length and width, a is a side, r is the radius, θ is the angle in radians (the calculator takes degrees and converts them), n is the number of sides and s is the length of one side.

Worked examples

Rectangle and square

A rectangle 8 ft by 5 ft has P = 2 × (8 + 5) = 26 ft. A square with a 5 ft side has P = 4 × 5 = 20 ft.

Triangle

A triangle with sides 5, 6 and 7 has P = 5 + 6 + 7 = 18. The sides must form a real triangle: any two sides added together must be longer than the third. Sides of 2, 3 and 6 fail, because 2 + 3 = 5 is less than 6, and the calculator will not accept them.

Circle, semicircle and sector

A circle with radius 5 has circumference 2 × π × 5 = 31.42. A garden bed with a 3 m radius needs 2 × π × 3 = 18.85 m of edging.

A semicircle with radius 5 has a curved edge of π × 5 = 15.71 plus the straight diameter of 10, so P = 25.71. The diameter counts, because the perimeter of the shape includes every edge.

A sector with radius 5 and a 60° angle has an arc of 5 × (π ÷ 3) = 5.24 plus two radii of 5 each, so P = 15.24.

L-shape

An L-shaped patio measures 10 ft wide and 8 ft high overall, with a rectangular corner removed. Its perimeter is 2 × (10 + 8) = 36 ft, and the size of the notch does not change that, because the notch only moves two edges inward without making the boundary any longer in total.

Regular polygon

A regular octagon with 3 ft sides has P = 8 × 3 = 24 ft.

Irregular shape from coordinates

A five-sided plot has corners at (0, 0), (6, 0), (6, 4), (3, 6) and (0, 4). The sides are:

  • (0, 0) to (6, 0): 6
  • (6, 0) to (6, 4): 4
  • (6, 4) to (3, 6): √(9 + 4) = √13 = 3.606
  • (3, 6) to (0, 4): √(9 + 4) = 3.606
  • (0, 4) to (0, 0): 4

Perimeter = 6 + 4 + 3.606 + 3.606 + 4 = 21.21. The coordinates mode also returns the area by the shoelace formula, which here is 30, the same as a 6 by 4 rectangle (24) plus a triangle with base 6 and height 2 (6).

Perimeter versus area

Perimeter tells you how much material runs along an edge, and area tells you how much surface lies inside it. A fence for a rectangular yard uses the perimeter, while the grass seed for the same yard uses the area. A 10 ft by 10 ft square and a 5 ft by 20 ft rectangle both cover 100 ft², but the square has a perimeter of 40 ft and the rectangle 50 ft.

Practical points

  • Enter every measurement in the same unit, and read the answer in that unit.
  • For fencing or trim, add an allowance for waste, gates, corners and cuts. The perimeter is the geometric length, not the quantity to buy.
  • Order the coordinates in sequence around the outline, either clockwise or counter-clockwise, so the edges do not cross.
  • For a shape built from several parts, find the outer boundary only. Edges where two parts meet are inside the shape and do not count.

Frequently asked questions

How do I calculate the perimeter of a shape?

Add the lengths of all its outer edges. For a rectangle that is 2 × (length + width), for a square 4 × side, for a triangle the sum of its three sides and for a circle 2 × π × radius.

What is the perimeter of an irregular shape?

Find the distance between each pair of neighboring corners with √((x2 − x1)² + (y2 − y1)²) and add them. The coordinates mode does this for you, listing the corners in order around the shape.

Does the notch of an L-shape change its perimeter?

No, as long as the notch is a rectangular corner cut out of an overall rectangle. The perimeter is still 2 × (overall width + overall height).

How is the perimeter of a semicircle different from half a circle circumference?

A semicircle perimeter includes the straight diameter as well as the curved edge. The curve is πr and the diameter is 2r, so P = πr + 2r.

Can two shapes have the same area but different perimeters?

Yes. A 10 ft by 10 ft square and a 5 ft by 20 ft rectangle both have 100 ft² of area, but their perimeters are 40 ft and 50 ft.

Why does the triangle perimeter calculator reject some sides?

Three lengths only form a triangle if each is shorter than the sum of the other two. Sides of 2, 3 and 6 cannot meet, so no perimeter exists for them.

Mark Danny

Mark Danny

Mark Danny builds and maintains the free calculators and guides on Area of Irregular Shapes Calculator. Every calculator page explains its formula and shows a worked example, so you can check the working yourself. Spotted a mistake or have a suggestion? Email gulsher.hingoro101@gmail.com.

Articles: 559