CalcTray

Rectangle Calculator

Find area, perimeter, and diagonal of a rectangle

Must be greater than 0

Must be greater than 0

Embed this calculator

Add it to your website or blog

Embed this calculator

Paste this code into your website's HTML.

Optional: auto-resize iframe to fit content

Add this snippet to your page so the iframe height adjusts automatically after each calculation:

Rectangle Calculator Formula

Area of a rectangle:

A = length × width

Perimeter of a rectangle:

P = 2 × (length + width)

Diagonal of a rectangle:

d = √(length² + width²)

How to Use This Calculator

  1. Enter the length of the rectangle.
  2. Enter the width of the rectangle.
  3. Click Calculate to see area, perimeter, and diagonal.
  4. Share your result by copying the URL that updates automatically after calculating.

Frequently Asked Questions

What is the formula for the area of a rectangle?

The area of a rectangle is A = length × width. This equals the number of unit squares that fit inside the shape. For example, a rectangle 10 meters long and 5 meters wide has an area of 50 square meters.

How do you find the perimeter of a rectangle?

The perimeter is the total distance around the outside: P = 2 × (length + width). Unlike area, perimeter is measured in linear units (meters, feet), not square units.

What is the diagonal of a rectangle?

The diagonal connects two opposite corners and is calculated using the Pythagorean theorem: d = √(length² + width²). If you need to calculate angles of the diagonal, use the Pythagorean theorem calculator.

What units are used?

This calculator is unit-agnostic. If you enter measurements in feet, area is in square feet, perimeter in feet, and diagonal in feet. Just be consistent with your units. To convert area units, use the area converter.

Is a square a rectangle?

Yes. A square is a special rectangle where all four sides are equal. The area formula A = length × width still applies — for a square, it becomes A = s². Similarly, the diagonal of a square simplifies to d = s × √2.

Can I share my calculation?

Yes. After clicking Calculate, the URL updates with your length and width values. Copy and share the URL to let anyone open the same pre-filled form with all three results.

Further Reading

Related Calculators