Rectangle Calculator
Enter a length and width to get the area, perimeter, and diagonal of a rectangle.
Area
40
Area = length × width. An 8 by 5 rectangle covers 40 square units.
Perimeter
26
Diagonal
9.434
How it works
A rectangle is pinned down by two numbers, its length and its width. From those, area, perimeter, and the diagonal all fall out with simple arithmetic.
Area is length × width — an 8 by 5 rectangle covers 40 square units. Perimeter, the distance all the way around, is 2 × (length + width), which comes to 26 here. The diagonal uses the Pythagorean theorem: √(8² + 5²), or about 9.43.
Change either measurement and every result updates on the spot. Answers round to four decimals, which is more than enough for flooring, framing, and paper layouts.
Frequently asked questions
Does it matter which side I call length and which I call width?
For area, perimeter, and the diagonal, no. Multiplication and addition don't care about the order, so swapping the two boxes gives the identical answers.
How is the diagonal worked out?
The diagonal splits the rectangle into two right triangles, so it's the hypotenuse of one of them: √(length² + width²). That's why a 3 by 4 rectangle has a tidy diagonal of exactly 5.
Can I use this for a square?
A square is just a rectangle with equal sides, so enter the same number for length and width. You'll get the square's area, perimeter, and diagonal without needing a separate tool.