Perimeter Calculator - Multi-Shape Sum of Sides
Use this perimeter calculator to find the boundary length of a rectangle, square, triangle, circle, trapezoid, or parallelogram from the matching sides.
Perimeter Calculator
Results
What Is a Perimeter Calculator?
A perimeter calculator finds the total length of the boundary of a two-dimensional shape. Pick a shape, type the side lengths, and read the perimeter together with the contributing sides. It answers how much fence, trim, or edging you need to go all the way around a rectangle, square, triangle, circle, trapezoid, or parallelogram.
- • Fencing and garden edging: Estimate fencing, edging, or border material for a rectangular lawn, square bed, or triangular flower bed, then pair the perimeter with the cost per linear unit.
- • Trim, baseboard, and rails: Calculate the running length of baseboard, crown molding, or picture rail needed for a rectangular room or an L-shaped room built from two rectangles.
- • School and homework geometry: Confirm a textbook problem for the perimeter of a rectangle, square, triangle, trapezoid, parallelogram, or circle, with the side inputs and formula visible at the same time.
- • Crafts, baking, and sewing: Measure the perimeter of a quilt square, cake pan, pattern piece, or tabletop runner, and switch the linear unit to stay in centimeters, inches, or feet.
For straight-sided shapes the perimeter is the sum of the side lengths. For a circle the boundary is curved, so the perimeter takes the special name circumference with formula 2 * pi * r.
If you need the area of the same shape, the Area Calculator page uses the same shape selector and inputs to return the matching area.
How the Perimeter Calculator Works
The page applies one of six formulas based on the selected shape. It reads the matching side inputs, sums them (or uses 2 * pi * r for a circle), and returns the boundary length in the unit you chose.
- L, W: Length and width of a rectangle. Opposite sides are equal, so the perimeter is 2 * (L + W).
- s: Side of a square. The perimeter is 4 * s.
- a, b, c: Sides of a triangle. The perimeter is a + b + c. The sides must satisfy the triangle inequality.
- r: Radius of a circle. The circumference is 2 * pi * r and the diameter is 2 * r.
- a, b, c, d: Sides of a trapezoid (a + b + c + d) or parallelogram (2 * (a + b)).
For a parallelogram, only two distinct side lengths are needed because the other two sides are equal to the first two by the parallelogram property. The page reports side 3 and side 4 as copies of side 1 and side 2.
Worked example: a circle of radius 5
Radius = 5 ft, Shape = Circle.
P = 2 * pi * r = 2 * pi * 5 = 10 * pi.
P = 31.42 ft (diameter 10 ft).
The boundary of the circle is the circumference, equal to 10 * pi. The diameter row surfaces 2r so the pi relationship is visible at a glance.
According to Omni Calculator, the perimeter of a closed 2D shape equals the sum of the lengths of its sides, with the circle treated as a special case where the perimeter equals 2 * pi * r (the circumference)
For a deep dive on the circle path of the formula, including arc length and the rest of a circle's measurements, the Circle Length Calculator page covers the same 2 * pi * r relationship.
Key Concepts Explained
Four ideas come up every time you read a perimeter formula. Understanding them keeps the numbers honest and the result useful.
Boundary length vs. enclosed area
Perimeter is a length measured in linear units (cm, m, in, ft, yd). Area is a different quantity measured in square units (cm^2, m^2, ft^2). A 10 by 6 rectangle has perimeter 32 cm and area 60 cm^2; never add the two.
Opposite sides are equal in rectangles, squares, and parallelograms
In a rectangle the two lengths and the two widths are equal, so you only need to type one length and one width. In a parallelogram the two distinct side lengths appear twice each, so the page mirrors side 3 and side 4 from side 1 and side 2.
The circumference is a perimeter, not a special number
The circumference of a circle is just the perimeter of a circle, given its own name because the boundary is curved. The formula 2 * pi * r is the circle's version of summing the sides.
Triangle inequality is a hard rule
Three numbers only describe a real triangle if the longest side is strictly shorter than the sum of the other two. The page enforces that rule.
These four ideas are enough to read every formula on the page. The same rules also let you sanity-check the result by hand: count the sides, add the lengths, and confirm the unit label matches the side units.
For a regular polygon with n equal sides of length a, the perimeter is n * a; the Polygon Area Calculator page covers the matching area, apothem, and circumradius formulas for the same set of shapes.
How to Use This Calculator
The form has four steps. Follow them in order and the result is the perimeter of the chosen shape in the chosen linear unit, plus the contributing side lengths.
- 1 Choose a shape and enter the matching side inputs: Open the Shape dropdown and pick Rectangle, Square, Triangle, Circle, Trapezoid, or Parallelogram. Type the side lengths for the chosen shape. The form keeps the values you already typed for any other shape so you can compare results without re-entering numbers.
- 2 Pick a linear unit and read the result: Open the Linear unit dropdown and choose cm, m, in, ft, or yd. The unit is a label only, so the numeric perimeter does not change when you switch units. The Results panel shows the total Perimeter at the top, the Number of sides below, and the contributing Side 1 to Side 4 rows.
- 3 Handle validation errors: If a side is negative or a triangle violates the triangle inequality, the form stops and surfaces a clear error message. Fix the offending input and the result updates immediately.
- 4 Reset to the default rectangle example: Click Reset to restore the form to a 10 by 6 rectangle in centimeters. Use it to start a new measurement or to compare your own shape against the worked example on this page.
Practical example: a rectangular lawn is 12 m by 8 m. Set Shape to Rectangle, type 12 in Length, 8 in Width, and pick Meters. The Perimeter reads 40.
If you only know one side and the two adjacent angles of a triangle, the Triangle Calculator page solves the missing sides and angles before you return here to add them up.
Benefits of Using This Calculator
Four practical benefits of working with a single multi-shape perimeter tool instead of jumping between one-shape calculators.
- • Six shapes in one form: Rectangle, square, triangle, circle, trapezoid, and parallelogram share a single selector and a single Results panel. You do not need to keep six tabs open to compare the perimeter of a rectangle to the circumference of a circle.
- • Contributing side lengths are visible: The Results panel lists side 1 to side 4 next to the total. If a homework problem asks for a specific side, you can read it from the row instead of re-reading the input.
- • Validation over silent answers: The form refuses 1, 1, 3 as a triangle and rejects negative inputs, so the result is never a meaningless sum. The unit label is decoupled from the number, so switching from centimeters to feet does not re-scale the value.
- • Real-time updates with a clean reset: The Perimeter row updates as you type, and the Reset button restores the 10 by 6 rectangle in centimeters that matches the worked example on this page. Use it to start a new measurement or to verify the calculator against the formula.
Use the same workflow for everyday measurements: a quick perimeter, the side that drives the cost, and the unit the supplier charges.
For triangle sides given as fractions or mixed numbers, the Perimeter of a Triangle with Fractions Calculator page handles common denominators and a decimal check, so you can keep the triangle path here and the fraction path on the matching tool.
Factors That Affect Your Results
Four factors decide how trustworthy the number is, plus two caveats about scope.
Shape selection
Switching the shape selector changes the formula and the inputs the page reads. Choose the right shape for the boundary you actually have: a rectangular lawn is a rectangle, a round pool is a circle.
Side length accuracy
Every centimeter of error in a long side becomes a centimeter of error in the perimeter, so a rectangular lawn measured with a slack tape can produce a real shortfall in edging. Measure the longest side first and round to the nearest unit the supplier sells.
Triangle inequality
If the longest side is equal to or longer than the sum of the other two, the three numbers do not form a real triangle. The form surfaces a validation error so the result is never a meaningless sum.
Unit consistency
Mixing feet and inches, or mixing the radius and the diameter, is the most common reason a perimeter comes out wrong. Use the Linear unit selector to label every input the same way.
- • The page covers the six most common closed 2D shapes. Shapes outside the list (ellipse, annulus, kite, sector, rhombus) live on dedicated pages, and the closest peer is referenced in the concept cards above.
- • The unit selector changes the label, not the number. If you need to convert 10 cm into inches, the perimeter stays at 10 and the unit reads inches. Use a dedicated length converter for the actual conversion, then come back to the perimeter form.
These caveats are not unique to this page. Knowing them up front is what turns a calculator result into a number you can stake a materials order on.
According to Wikipedia (Circumference), the circumference of a circle is C = pi * d = 2 * pi * r, where pi is the ratio of a circle's circumference to its diameter, with decimal expansion 3.141592653589793...
According to Wolfram MathWorld, pi is the real number defined as the ratio of a circle's circumference to its diameter, with decimal expansion 3.1415926535897932384626433...
If the perimeter is going to drive a fence, deck, or garden border, the Fence Perimeter Calculator page takes the boundary length from this calculator and adds gate widths, panel counts, and post counts for the real project.
Frequently Asked Questions
Q: What is the formula for the perimeter of a rectangle?
A: The formula is P = 2 * (L + W), where L is the length and W is the width. Add the length and the width, then multiply by 2 because each side appears twice. A 10 by 6 rectangle has P = 32.
Q: How do I find the perimeter of a triangle?
A: Add the three side lengths: P = a + b + c. The triangle inequality requires that the longest side is shorter than the sum of the other two, or the three numbers do not form a real triangle. A 3-4-5 right triangle has P = 12.
Q: What is the difference between perimeter and circumference?
A: Perimeter is the generic name for the boundary length of any closed 2D shape. Circumference is the special name used for the boundary of a circle. The formula for a circle is 2 * pi * r, which is just the perimeter of a curved shape.
Q: Is perimeter measured in units or square units?
A: Perimeter is measured in linear units such as cm, m, in, ft, or yd. Square units are reserved for area, which measures how much flat ground a shape covers. A 10 by 6 rectangle has perimeter 32 cm and area 60 cm^2.
Q: How do I find the perimeter of a circle with this calculator?
A: Choose Circle from the Shape dropdown, type a positive radius, and read the perimeter. The result is the circumference, 2 * pi * r. The page also shows the diameter, so the ratio of perimeter to diameter is pi.
Q: Can this perimeter calculator handle a trapezoid or parallelogram?
A: Yes. Choose Trapezoid and type all four sides a, b, c, d in any order around the boundary. Choose Parallelogram and type just two distinct side lengths; the page reports the matching opposite sides as side 3 and side 4.