To count the area of a rectangle, multiply its length by its width — area = length × width — and if the rectangle is 4 units long and 5 units wide, the answer is exactly 20 square units. That single multiplication is all you need for any rectangle, because every rectangle can be split into a tidy grid of unit squares and length × width simply counts them all. The result is always expressed in square units, so measuring in centimetres gives you square centimetres (cm²), measuring in metres gives square metres (m²), and so on for any unit you choose. Once you have those two numbers — length and width — you can also pull out two related measurements with no extra work: the perimeter, which is 2 × (length + width) and tells you how far it is to walk around the outside, and the diagonal, which is √(length² + width²) by the Pythagorean theorem and tells you the corner-to-corner distance. The Rectangle Area Calculator handles all three at once: type your two sides, read the area, perimeter, and diagonal instantly.

how to count rectangle area
How to Count Rectangle Area, Perimeter, and Diagonal

The Rectangle Area Formula, in One Line

A rectangle is a four-sided polygon with four right angles, and opposite sides come in equal pairs. That regular structure is what makes the area formula the simplest in all of geometry: A = length × width, often written A = l × w. The two numbers you enter are the only measurements that define a rectangle, and their product gives the total flat space the shape takes up. There is no need to know the angles, the diagonal, or anything else — the area lives entirely in those two sides.

You do not need to worry about the order, either. Length times width and width times length give the same answer, because multiplication is commutative. By convention, length is usually the longer side and width is the shorter one, but the Rectangle Area Calculator accepts either number in either box, so you can never type them in the "wrong" order.

Why Multiplying Length and Width Counts Every Square Inside

The reason A = l × w works comes down to imagining the rectangle as a grid of tiny squares. If the rectangle is 5 units long and 4 units wide, its top edge can hold 5 unit squares side by side. Underneath that first row, you can stack another row of 5 squares, then another, until you have stacked 4 rows in total. The whole rectangle is now full of squares — 5 squares per row times 4 rows equals 20 squares — and each of those squares covers exactly one square unit of space. The area is therefore 20 square units.

This grid view also explains the units. Each unit square has dimensions of one unit by one unit, so its area is one square unit. Multiplying 5 by 4 counts twenty of those one-square-unit tiles. Measuring in centimetres instead means each tile is 1 cm × 1 cm, so the same rectangle covers 20 cm². Measuring in metres gives 20 m². The formula does not change; only the size of the unit square changes. This is also why you always square the unit in the answer — area is two-dimensional, so the linear unit becomes squared.

Perimeter and Diagonal From the Same Two Sides

Length and width do double duty. Once you have measured the two sides of a rectangle, you already have everything you need to find its perimeter and diagonal without taking any new measurements.

The perimeter is the total distance around the outside edge. Because opposite sides are equal, a rectangle has two lengths and two widths to add together. The formula is perimeter = 2 × (length + width). For a 4 by 5 rectangle, that gives 2 × (4 + 5) = 2 × 9 = 18 units of perimeter. Perimeter is the measurement you reach for when buying fencing, cutting skirtings, or framing a picture, because all of those jobs depend on the length of material that has to wrap around the outside.

The diagonal is the straight line that joins two opposite corners. Draw the diagonal, and you split the rectangle into two identical right-angled triangles. Each triangle has the length of the rectangle as one leg, the width as the other leg, and the diagonal as the hypotenuse. The Pythagorean theorem therefore applies: diagonal = √(length² + width²). For the same 4 by 5 rectangle, that is √(4² + 5²) = √(16 + 25) = √41 ≈ 6.40 units. Whole-number diagonals appear for Pythagorean triples such as 3-4-5 and 6-8-10, which is why those dimensions turn up so often in textbook problems and in real measurements too.

Count Rectangle Area Using the Free Calculator

  1. Enter the length of the rectangle, for example 4.
  2. Enter the width of the rectangle, for example 5.
  3. Read the area (20 square units), perimeter, and diagonal, which update instantly as you type.

Add an optional unit label such as m, ft, or in if you want to keep a record of which unit you measured in. The calculator also flags when your length and width are equal, which is the special square case, so you know your inputs describe a square rather than an off-square rectangle. Every calculation runs locally in your browser, which means the numbers update as you type and never need a round-trip to a server.

Where Each Rectangle Measurement Actually Matters

Different jobs need different rectangle measurements, and it helps to know which one to reach for. The same rectangle can call for three different numbers depending on what you are doing with it.

MeasurementWhat it tells youCommon use
AreaFlat space the rectangle covers, in square unitsFlooring, paint, fabric, raised garden beds, screen real estate, room planning
PerimeterTotal distance around the four sidesFencing, framing, skirting board, picture rails, edge trim
DiagonalStraight-line distance between opposite cornersTV and monitor screen sizes, checking a frame is square, fitting long objects across a space

For example, when you are buying laminate flooring for a 4 m × 5 m room, the area of 20 m² tells you how much flooring to order. When you are running a picture rail along the same wall, the perimeter of 18 m tells you how much rail to buy. When you are checking whether a large TV will fit between two opposite corners of the room, the diagonal of about 6.40 m tells you the maximum screen diagonal you can swing through the space. The three numbers describe the same rectangle but answer three different practical questions.

Reading the Answer in the Right Unit

The numbers on the calculator are unit-agnostic — they reflect whatever unit you typed in. Type 4 and 5 without units, and you get 20, 18, and about 6.40 in generic square units and units. Type 4 m and 5 m, and you get 20 m², 18 m, and about 6.40 m. The square in the unit is important: area is two-dimensional, so you square the linear unit. The same numeric length produces a much smaller physical rectangle in centimetres than in metres, and the unit on the answer makes that explicit.

Mixing units is the most common mistake. If the length is in metres and the width is in feet, the product does not give a real area in either unit — the two inputs are talking about different scales. Convert both sides to the same unit first, or use a separate converter if you are unsure. Once both inputs share a unit, the area, perimeter, and diagonal all come out in consistent units you can use directly.

A Square Is Just a Rectangle With Equal Sides

A square is the special case where length equals width. Every square is a rectangle — it still has four right angles and two pairs of equal sides — but the two defining numbers collapse into one. Enter the same value into both boxes of the Rectangle Area Calculator and the results simplify into the familiar square formulas.

  • Area becomes side².
  • Perimeter becomes 4 × side.
  • Diagonal becomes side × √2.

A 1.5 m × 1.5 m square coffee table, for instance, has an area of 2.25 m², a perimeter of 6 m, and a diagonal of about 2.12 m. The calculator automatically flags the equal-sides case so you do not have to remember the square formulas separately, and the same tool works as a quick square calculator whenever you enter matching numbers.

If you're weighing options, How to Calculate Sector Area in Radians: A = ½θr² covers this in detail.

If you're weighing options, Triangle Area in Square Feet from Base and Height covers this in detail.