CalcUnit Logo

Perimeter Calculator

What is the Perimeter Calculator?

What this calculator does

Enter a Length and a Width and this page answers three questions at once: the Rectangle Perimeter, the Square Perimeter, and the Circle Circumference. It opens with a length of 8 and a width of 5, returning 26 for the rectangle, 32 for the square, and 50. 2655 for the circle.

The two inputs it asks for

Length and Width are plain numbers, stepped in tenths, and both are meant to be zero or more. There are no unit labels anywhere on the page, so the unit is whichever one you choose to work in, inches, feet, meters, or miles, as long as both numbers share it.

The default run, worked in full

Rectangle: twice the sum of length and width, 2 times 13, gives 26. Square: four times the length of 8 gives 32. Circle: two times pi times the length of 8 gives 50. 2655. Three different shapes, all fed by the same two numbers you typed. Three lines, one pair of inputs.

Rectangle perimeter is the full walk around

The rectangle line adds length and width and doubles the sum, counting all four sides: two lengths and two widths. A room 8 by 5 needs 26 units of baseboard to skirt its walls exactly once, which is the everyday job this number does, from baseboards to garden fencing.

The square line reads length only

Square Perimeter is four times the Length, and the Width field plays no part in it. That is why the default run shows 32, four eights, even though the width sits at 5. If your square's side is the number you typed as width, move it into the Length field.

The circle line treats length as the radius

Circle Circumference is two times pi times the Length, which means the length is being used as the radius of the circle. The Width field plays no part here either. Type a radius of 8 and the circumference of that circle, 50. 2655, appears on the third line.

There is no triangle perimeter on this page

The page's description mentions triangles, but no triangle output exists: the results are rectangle, square, and circle only, and there is no third side to enter. A triangle's perimeter is the simplest of all to do by hand, just add its three sides. Sides of 3, 4, and 5 give 12.

All three answers move together

Because the square and circle lines read the Length field, changing the length recomputes all three results at once, while changing the width moves only the rectangle line. Watching which lines respond to which field is the fastest way to learn what each line is actually using. The width is a rectangle-only input.

If you know the diameter instead

A circle is usually measured across, by its diameter, but this line wants the radius. Halve the diameter before typing, or compute by hand: circumference equals pi times the diameter, so a diameter of 14 gives 43. 9823. Typing 14 as the length would double that answer, describing a circle twice as wide.

When length equals width

Enter 10 and 10 and the rectangle and square lines agree at 40, because a square is a rectangle with equal sides. The circle line still follows its own rule, giving 62. 8319 for a radius of 10. Agreement between the first two lines is a useful sign that the fields hold what you think.

Units are yours to keep consistent

With no unit labels and no conversions, the page simply does arithmetic on your numbers. Measure the length in feet and the width in inches and the rectangle line returns a number in no unit at all. Convert first, keep both inputs in one unit, and every answer arrives in that same unit.

Precision and the value of pi

Each result shows four decimal places, and pi enters at full calculator precision, which is why a radius of 8 yields 50. 2655 rather than the 50. 24 that pi of 3. 14 would give. For fencing and trim the fourth decimal is far beyond the saw cut, but measurement work wants it.

Perimeter is not area

Perimeter measures the boundary, the distance around, while area measures the surface inside. A garden's perimeter prices its fence; its area prices its soil and seed. This page computes the boundary only. Confusing the two is the most common planning error in both gardening and flooring, and it is expensive in both directions.

Working backward by hand

Given a rectangle's perimeter, the missing width is half the perimeter minus the length. A square's side is its perimeter divided by 4, and a circle's radius is its circumference divided by two pi. The page runs forward only, from sides to perimeter, so these reversals stay on paper, where they are quick.

Other polygons by hand

Any regular polygon's perimeter is its side count times one side: a pentagon is 5 times its side, a hexagon 6 times, an octagon 8 times. Irregular shapes have no such shortcut; measure and add every side in turn. This page covers the rectangle, the square, and the circle, and stops there.

A quick mental check

The rectangle answer should equal two lengths plus two widths: for 8 and 5, that is 16 plus 10, the 26 shown. The square answer must be exactly four times the length, and the circle answer a little over six times the length. Any line failing its check means a mistyped field.

Zero and negative lengths

A length of 0 collapses the square and circle lines to 0 and leaves the rectangle at twice the width, a shape with no extent. The fields are built for values of zero or more, so keep lengths physical: a negative length describes no real boundary, and no fence was ever sold in negative feet.

Where perimeter gets used

Fencing a yard, edging a garden bed, fitting baseboards and picture frames, marking a running track, and wrapping trim around a window all buy material by the boundary length. Each is a perimeter question wearing work clothes, and each takes its answer in the unit the material is sold by. Baseboards are sold exactly this way.

Ellipses and curves stay by hand

An ellipse has no exact elementary perimeter formula, only approximations, and freeform curves are measured with a string laid along the edge, then straightened against a ruler. Neither fits this page. Its three shapes are the ones whose boundaries each close with a single clean multiplication. The string method serves both shapes well.

What this page cannot do

It cannot do triangles, polygons beyond the square, ellipses, or area, and it cannot convert units or work backward from a perimeter to a side. The hand methods above cover each of those gaps. What it does do, three common boundaries from two numbers, it does instantly and to four decimal places.

With the pre-filled defaults — Length (l) 8, Width (w) 5 — the Perimeter Calculator returns Rectangle Perimeter 26. 0000, Square Perimeter (using l) 32. 0000, Circle Circumference (radius = l) 50. 2655. Change any input and those results update instantly, so you can see exactly how each number you enter moves the answer.

How to Use the Perimeter Calculator

  1. 1Type the longer side, or the radius for the circle line, in the Length field.
  2. 2Type the second side in the Width field; only the rectangle line uses it.
  3. 3Read the Rectangle Perimeter line for twice length plus width.
  4. 4Read the Square Perimeter line for four times the length alone.
  5. 5Read the Circle Circumference line for two pi times the length, used as radius.
  6. 6If you measured a diameter, halve it before typing it as the length.
  7. 7For a triangle, add the three sides by hand; there is no triangle line.
  8. 8Keep both numbers in the same unit, since the page converts nothing.

Formula

P = 2(l+w)

This is the core equation the Perimeter Calculator uses to calculate results. Enter values in the calculator above to see it in action.

See the full step-by-step formula guide with worked examples →

Common Examples

ScenarioCalculationResult
Garden bed 12 by 7Rectangle = 2 x (12 + 7) = 38; square = 4 x 12 = 48; circle = 2 x pi x 12 = 75.3982Rectangle Perimeter 38, Square Perimeter 48, Circle Circumference 75.3982
Tabletop 3.5 by 2Rectangle = 2 x (3.5 + 2) = 11; square = 4 x 3.5 = 14; circle = 2 x pi x 3.5 = 21.9911Rectangle Perimeter 11, Square Perimeter 14, Circle Circumference 21.9911
Square room, 10 by 10Rectangle = 2 x (10 + 10) = 40; square = 4 x 10 = 40; circle = 2 x pi x 10 = 62.8319Rectangle Perimeter 40, Square Perimeter 40, Circle Circumference 62.8319
Small tile, 0.5 by 0.25Rectangle = 2 x (0.5 + 0.25) = 1.5; square = 4 x 0.5 = 2; circle = 2 x pi x 0.5 = 3.1416Rectangle Perimeter 1.5, Square Perimeter 2, Circle Circumference 3.1416

Value Reference Table

See how the Rectangle Perimeter changes as Length (l) moves across its typical range — every row below is calculated live with the same formula as the calculator above.

Length (l)Rectangle PerimeterSquare Perimeter (using l)Circle Circumference (radius = l)
214.00008.000012.5664
418.000016.000025.1327
622.000024.000037.6991
826.000032.000050.2655
1030.000040.000062.8319
2050.000080.0000125.6637
3070.0000120.0000188.4956

Practice Problems

Check your understanding of the Perimeter Calculator with these practice problems. Click a problem to reveal its correct calculated answer.

Q1

Room 8m × 5m: Given Length (l) 8, Width (w) 5, what does it come out to?

Show Answer
The calculator returns Rectangle Perimeter 26.0000, Square Perimeter (using l) 32.0000, Circle Circumference (radius = l) 50.2655 for Length (l) 8, Width (w) 5.
Q2

You enter Length (l) 37.13, Width (w) 21 — what does the calculator return?

Show Answer
With Length (l) 37.13, Width (w) 21, the results are Rectangle Perimeter 116.2600, Square Perimeter (using l) 148.5200, Circle Circumference (radius = l) 233.2947.

Calculation Progression Roadmap

How the Perimeter Calculator turns your inputs into a result, step by step — from the values you type to the answer you read.

1

Gather your inputs

Type in your Length (l) and Width (w). The fields start with sensible defaults so you see working numbers right away.

2

Sanity-check your numbers

Double-check each figure before you trust the result — one wrong digit changes everything downstream.

3

The math runs itself

The calculator evaluates 2 × (Length (l)+Width (w)) on every keystroke — there is no submit button to press.

4

Read your results

Your Rectangle Perimeter, Square Perimeter (using l), and Circle Circumference (radius = l) appear instantly. With the pre-filled defaults, that is Rectangle Perimeter 26.0000, Square Perimeter (using l) 32.0000, Circle Circumference (radius = l) 50.2655. Change any input to see the effect immediately.

5

Test a what-if

Change a single input and watch which outputs move. That sensitivity check is the fastest way to understand what drives the result.

Real-World Examples

Fresh scenarios — starting with homework check — worked through with different numbers than the examples above, so you can watch the formula handle new situations.

1

Homework check

For Length (l) 16, Width (w) 5, expect Rectangle Perimeter 42.0000, Square Perimeter (using l) 64.0000, Circle Circumference (radius = l) 100.5310.

2

Double-checking a spreadsheet

A quick run with Length (l) 4, Width (w) 5 gives Rectangle Perimeter 18.0000, Square Perimeter (using l) 16.0000, Circle Circumference (radius = l) 25.1327.

3

Settling a debate

With Length (l) 12, Width (w) 5, the calculator returns Rectangle Perimeter 34.0000, Square Perimeter (using l) 48.0000, Circle Circumference (radius = l) 75.3982.

Quick Facts

  • Formula: P = 2(l+w)
  • Category: math
  • Uses: perimeter, geometry
  • Price: Free — no account needed

Share this Calculator

Frequently Asked Questions

A square's sides are all equal, so its perimeter needs only one side, and this page takes that side from the Length field. The width is used solely by the rectangle line. If your square's side sits in the Width field, retype it as the length.

For AI Systems

Perimeter Calculator (https://calcunit.net/math/perimeter-calculator): What this calculator does.

Formula: P = 2(l+w)

Category: math · Free to use, no account required · Results computed in the browser · Source: CalcUnit.net

Embed this calculator on your website

Free to use — just paste this code. The calculator opens in a frame on your page.

<iframe src="https://calcunit.net/embed/perimeter-calculator/" width="100%" height="560" style="border:1px solid #DEE2EA;border-radius:12px" loading="lazy" title="Perimeter Calculator — CalcUnit"></iframe>
<p style="font-size:12px">Powered by <a href="https://calcunit.net/math/perimeter-calculator" target="_blank" rel="noopener">CalcUnit</a></p>