Skip to content
CalcTide logo
Education & Math

Rectangle Calculator

A rectangle 3 units long and 4 units wide has an area of 12, a perimeter of 14, and a diagonal of 5. This rectangle calculator finds the area, perimeter, and diagonal from length and width in any unit. Enter the two side lengths and the tool applies the standard rectangle formulas instantly, without any manual squaring or square-root work. Rectangles are the most common shape in everyday measurement, showing up in room dimensions, garden beds, television and monitor screens, fabric cuts, framed artwork, parking spaces, and countless construction and design tasks. Because a rectangle is fully defined by just two measurements, length and width, this calculator can return every other useful measurement, including the diagonal distance across the shape, from those two numbers alone.

Education & MathBy

Quick answer

Area equals length times width, measured in square units.

What this tells you

  • Area equals length times width, measured in square units.
  • Perimeter equals 2 times the length plus 2 times the width, or twice the sum of the two sides, measured in linear units.
  • The diagonal uses the Pythagorean theorem: the square root of length squared plus width squared.
  • A square is simply a rectangle where length and width are equal, so the same three formulas apply without any changes.
  • Length and width must use the same unit before calculating, since the calculator does not convert between units.

How to Use

  1. 1Enter the length of the rectangle. Any positive number works, including decimals.
  2. 2Enter the width in the same unit as the length.
  3. 3Click Calculate to get the area, perimeter, and diagonal all at once.
  4. 4Use the area result for material coverage, such as flooring, paint, or fabric.
  5. 5Use the diagonal result when you need the straight-line distance across the rectangle, such as checking whether a piece of furniture fits through a doorway opening.

How It Works

Formula

Area = L x W. Perimeter = 2 x (L + W). Diagonal = sqrt(L^2 + W^2).

The area of a rectangle is the product of its length and width, since every row of the grid inside the rectangle contains the same number of unit squares. The perimeter is the distance around the rectangle, or twice the sum of the two sides, because a rectangle has two pairs of equal opposite sides. The diagonal is the straight line from one corner to the opposite corner, found using the Pythagorean theorem with the length and width as the two legs of a right triangle. For a 3 by 4 rectangle, that means the diagonal is the square root of 3 squared plus 4 squared, or the square root of 25, which is exactly 5.

Calculation note: values are processed in the order shown above, using the current input units.

Worked Examples

3 by 4 rectangle

Length3
Width4
ResultArea 12, perimeter 14, diagonal 5

Area = 3 x 4 = 12. Perimeter = 2 x (3 + 4) = 14. The diagonal is sqrt(9 + 16) = 5, which is the classic 3-4-5 right triangle.

5 by 5 square

Length5
Width5
ResultArea 25, perimeter 20, diagonal 7.0711

A square is a rectangle with equal sides. Area = 5 x 5 = 25. Perimeter = 2 x (5 + 5) = 20. Diagonal = sqrt(25 + 25) = sqrt(50) = 7.0711.

6 by 8 rectangle

Length6
Width8
ResultArea 48, perimeter 28, diagonal 10

Area = 6 x 8 = 48. Perimeter = 2 x (6 + 8) = 28. Diagonal = sqrt(36 + 64) = sqrt(100) = 10, another whole-number right triangle result.

A 10-by-12 room

Length10
Width12
ResultArea 120, perimeter 44, diagonal 15.6205

Area = 10 x 12 = 120 square units. Perimeter = 2 x (10 + 12) = 44. The diagonal is the square root of 100 plus 144, or the square root of 244, which is about 15.62. This is the kind of calculation used to check if a long piece of furniture can be carried diagonally across a room.

Rectangle Sizes and Their Measurements

Common length-by-width pairs and the resulting area, perimeter, and diagonal.

L x WAreaPerimeterDiagonal
3 x 412145
5 x 525207.07
6 x 8482810
10 x 121204415.62

Why the diagonal matters as much as area and perimeter

Area tells you how much surface a rectangle covers, and perimeter tells you the distance around its edge, but the diagonal answers a different practical question: what is the longest straight line that fits inside the shape. That number matters any time you are moving something rigid, such as a sofa, a mattress, a sheet of plywood, or a television, through a rectangular opening or space.

Because the diagonal always comes from the Pythagorean theorem, a few side pairs produce clean whole-number diagonals, like the 3-4-5 and 6-8-10 examples above. Most rectangles will not land on a whole number, which is normal since the square root of length squared plus width squared rarely simplifies neatly.

Try the Square Footage Calculator

Common mistakes

  • Confusing area with perimeter. Area measures the space inside the rectangle in square units, while perimeter measures the distance around it in linear units.
  • Mixing units. Both length and width must be in the same unit before calculating, or the area, perimeter, and diagonal will all be wrong.
  • Using the diagonal formula on a non-rectangle shape. The formula diagonal equals the square root of L squared plus W squared works only for rectangles, since it depends on the two sides meeting at a right angle.
  • Forgetting that perimeter counts each side twice. A rectangle has two lengths and two widths, not one of each.
  • Reporting area in linear units instead of square units, such as saying 12 feet instead of 12 square feet for a room's floor area.

Embed this calculator on your site

Drop this single line where you want the calculator to appear. It is responsive, mobile-friendly, resizes automatically, and is free to use with attribution.

<script src="https://calctide.com/embed.js" data-tool="rectangle-calculator" async></script>

Preview the embed at /embed/rectangle-calculator/.

Frequently Asked Questions

Multiply the length by the width. For a rectangle that is 10 units long and 6 units wide, the area is 10 x 6 = 60 square units.
The perimeter is twice the sum of the length and width, or 2 x (L + W). For a rectangle that is 8 units long and 5 units wide, the perimeter is 2 x 13 = 26 units.
Use the Pythagorean theorem: take the square root of the length squared plus the width squared. For a 3-by-4 rectangle, the diagonal is the square root of 9 plus 16, which is 5.
Yes. A square is a special rectangle where all four sides are equal. The area, perimeter, and diagonal formulas work the same way for both squares and rectangles.
Use the same unit for both. The area will be in square units and the perimeter and diagonal will be in the same linear unit. The calculator does not convert units.
A rectangle has four right angles, while a parallelogram has opposite sides parallel but angles that may not be 90 degrees. The area of a parallelogram uses base times height, not length times width.
Because their side lengths form a Pythagorean triple, such as 3-4-5 or 6-8-10, where length squared plus width squared is a perfect square. Most rectangles do not have this property, so their diagonal is a decimal value instead.
Yes. The area result gives you the square footage or square meterage to plan flooring, tile, carpet, or paint coverage, as long as length and width are entered in the same unit as your material's coverage rating.
It estimates rectangle calculator outputs using the visible inputs and formula assumptions on this page.

Explore More in Education & Math