Area of a Rectangle Calculator

Calculate the area, perimeter, and diagonal of a rectangle. Enter any two values and the rest update instantly.

Unit:
cm
cm
cm²
cm
cm
A  =  l  ×  w
P  = 2 × ( l  +  w )
d  = √( l2  +  w2 )
l w d A

Rectangle Formulas

A rectangle has four right angles and opposite sides equal in length. Given length (l) and width (w), three properties can be derived:

PropertyFormula
AreaA = l × w
PerimeterP = 2 × (l + w)
Diagonald = √(l² + w²)

The diagonal formula comes directly from the Pythagorean theorem — a diagonal splits the rectangle into two right triangles.

How to Calculate

Area

Multiply length by width:

A = l × w

Example: A room 6 m × 4 m → A = 6 × 4 = 24 m²

Perimeter

Add both sides and double:

P = 2 × (l + w)

Example: 6 m × 4 m → P = 2 × (6 + 4) = 20 m

Diagonal

Apply the Pythagorean theorem:

d = √(l² + w²)

Example: 6 m × 4 m → d = √(36 + 16) = √52 ≈ 7.21 m

Working Backwards from Any Two Values

The calculator accepts any two fields and derives the other three. Here is how each combination is solved:

Known valuesMethod
l + wDirect: A = l × w, P = 2(l+w), d = √(l²+w²)
l + Aw = A / l
l + Pw = P/2 − l
l + dw = √(d² − l²)
w + Al = A / w
w + Pl = P/2 − w
w + dl = √(d² − w²)
A + PSolve t² − (P/2)t + A = 0
A + dSolve t² − √(d²+2A) · t + A = 0
P + dSolve t² − (P/2)t + ((P/2)²−d²)/2 = 0

Not every pair has a solution. If the values are geometrically incompatible — for example, a diagonal shorter than one of the sides — the calculator will not produce a result.

Practical Examples

ObjectLengthWidthAreaPerimeterDiagonal
A4 paper29.7 cm21.0 cm623.7 cm²101.4 cm36.4 cm
Standard door200 cm80 cm1.60 m²560 cm215.4 cm
Tennis court (singles)23.77 m8.23 m195.6 m²64.0 m25.16 m
Football pitch105 m68 m7140 m²346 m124.7 m
Letter paper (US)27.94 cm21.59 cm603.2 cm²99.06 cm35.13 cm

Area vs. Perimeter

These two properties measure different things:

  • Area measures the surface enclosed — used for flooring, paint, or fabric coverage.
  • Perimeter measures the boundary length — used for fencing, framing, or trim.

Doubling just one side doubles the area. Scaling both sides by a factor k multiplies the area by k² but the perimeter only by k.

Frequently Asked Questions

What is the formula for the area of a rectangle?

The area of a rectangle is A = l × w, where l is the length and w is the width. Both dimensions must be in the same unit; the result is in the corresponding square unit (e.g. cm²).

How do I find the perimeter of a rectangle?

The perimeter is P = 2 × (l + w). It is the total length of all four sides. For a 10 cm × 5 cm rectangle, the perimeter is 2 × (10 + 5) = 30 cm.

How do I calculate the diagonal of a rectangle?

The diagonal uses the Pythagorean theorem: d = √(l² + w²). For a 10 cm × 5 cm rectangle, d = √(100 + 25) = √125 ≈ 11.18 cm. Both diagonals of a rectangle are always equal in length.

Can I find the sides if I only know the area and perimeter?

Yes. If A = l × w and P = 2(l + w), then l and w are the two roots of t² − (P/2)t + A = 0. A real solution exists only when (P/2)² ≥ 4A. Enter both values into the calculator and it solves the equation for you.

What units does this calculator support?

The unit selector supports mm, cm, m, km (metric) and in, ft, yd, mi (imperial). All five fields use the same linear unit; Area is automatically shown in the corresponding squared unit (e.g. cm²). Changing the unit converts all values proportionally.