InfiniteCalcs

Diagonal Calculator

A diagonal calculator finds the straight-line distance between opposite corners of a rectangle or square.

Diagonal Calculator Tool

Enter your values in the calculator above, then use the explanations below to understand the result, check assumptions, and compare scenarios.

About this calculator

A diagonal calculator finds the straight-line distance between opposite corners of a rectangle or square. This measurement is useful for layout, framing, fabrication, displays, flooring, and field checks because a correctly sized rectangle should have matching corner-to-corner diagonals.

For a rectangle with length l and width w, the diagonal is d = √(l² + w²). For a square with side s, this simplifies to d = s√2. The relationship comes directly from the Pythagorean theorem because the diagonal forms the hypotenuse of a right triangle.

The diagonal is a linear measurement and uses the same unit as the side dimensions. In field layout, equal diagonals are a strong check that a four-sided frame is square, provided opposite sides are also correctly dimensioned.

Worked examples

12 ft by 9 ft rectangle

A rectangular frame measures 12 ft by 9 ft.

  1. d = √(12² + 9²)
  2. d = √225
  3. d = 15 ft

Result: The corner-to-corner diagonal is exactly 15 ft.

Practical tips

  • Use the same units for length and width.
  • Measure between the same corresponding corner points when comparing diagonals.
  • Keep full precision until the final result.
  • Use diagonal checks together with side measurements for field squaring.

Common mistakes

  • Adding length and width instead of using the Pythagorean theorem.
  • Mixing inches and feet without conversion.
  • Using half a side length by mistake.
  • Assuming equal diagonals alone prove every four-sided shape is a rectangle.

Key terms

Diagonal
A straight line connecting opposite corners of a polygon or solid face.
Hypotenuse
The longest side of a right triangle, opposite the right angle.
Pythagorean theorem
The relationship a² + b² = c² for the sides of a right triangle.
Square check
A field verification comparing diagonals and side dimensions to confirm a rectangular layout.

Frequently asked questions

How do I calculate the diagonal of a rectangle?
Square the length and width, add those values, and take the square root: d = √(l² + w²).
What is the diagonal formula for a square?
For a square with side length s, the diagonal is d = s√2 because both legs of the right triangle are equal.
Why are diagonals useful when laying out a rectangle?
If opposite sides are correct and both corner-to-corner diagonals match, the layout is square rather than skewed.
Does a diagonal use square units?
No. A diagonal is a distance, so it is reported in linear units such as feet, inches, meters, or centimeters.