12 × 16 ft footing or deck
Show the working
√(12² + 16²) = √400 = 20 ft. Pull both diagonals. A measured 20 ft 1 in is 1 in long, which is outside a ⅛ in tolerance, so the layout needs to be pushed square before it is built on.
Measure both diagonals. When each reads 20′, the corners are square.
Pull both diagonals. They should match each other and this number.
Enter a measured diagonal to check your layout.
Wondering how to square a building? Type two sides and get the diagonal that proves the corner square. This squaring calculator doubles as a diagonal calculator for any rectangle, and scales 3-4-5 up to 6-8-10 or 9-12-15 for the longest check your foundation or deck allows. A footing ½ in out at the corner is a problem you meet again at every wall, floor and roof above it.
Quick answer A 12 × 16 ft rectangle is square when both diagonals measure 20 ft. For a quick corner check, mark 3 ft along one side and 4 ft along the other: the line between the marks reads 5 ft when the corner is a right angle. Any multiple works too: 6-8-10, 9-12-15 or 12-16-20.
A rectangle's diagonal is fixed by its two sides. Lay out the length and the width, and if the corner-to-corner distance matches the calculated diagonal, the corners are right angles. The 3-4-5 check is the same theorem with sides picked to make the arithmetic easy: 3² + 4² = 5². Multiply all three by one number and it still holds, which is why the 345 square method and the 3 4 5 square rule scale from a quick corner check to a whole foundation.
The practical test is a diagonal measured against a tolerance, which is what a foundation square calculator checks. Pull both diagonals. They should match each other, and match the calculated value, to within the tolerance you set. The default is ⅛ in (3 mm) and you can change it.
Staking the four corners, pulling both diagonals and moving a corner stake until the readings agree is the whole method. Crews call the corner check the 3 4 5 triangle or the 345 triangle. This page also works as a diagonal of a rectangle calculator, so the arithmetic holds for any sides, not just 3 and 4.
One 3-4-5 check squares only one corner. It cannot catch a layout that has drifted into a parallelogram, which is why the diagonals get pulled as well. The step-by-step list below puts the two checks together.
Once the corners are square, lay out the patio with the paver calculator, the steps with the stair calculator or the rafters with the roof pitch calculator.
a, b = the two sides, c = the diagonal, k = the base unit.
diagonal = √( side A² + side B² ) square when measured diagonal ≈ calculated diagonal 3-4-5: if the base unit is k, the sides are 3k, 4k and 5k because (3k)² + (4k)² = (5k)²
√(12² + 16²) = √400 = 20 ft. Pull both diagonals. A measured 20 ft 1 in is 1 in long, which is outside a ⅛ in tolerance, so the layout needs to be pushed square before it is built on.
A base unit of 4 ft gives 12, 16 and 20 ft, the same triangle as the 12 × 16 layout. A base of 3 ft gives 9, 12 and 15 ft. Use the longest one you can mark without leaving the walls, because a small tape error matters less over a long check.
Mark 3.6 m along one side and 4.8 m along the other. The distance between the marks should be 6 m. The theorem does not care about the unit, so the same ratio works in millimetres, metres, feet or inches.
The calculator gives you the diagonal. These steps are the check on the ground, and they work for a foundation, a slab or a deck as well as a building, with nothing but a tape and string.
The diagonal is the square root of the two sides squared and added, which is the whole sum behind a diagonal calculator. The first table gives it for common layouts, from a deck to a building, and it is the number that proves a rectangle square. The second is for a square, where the diagonal is just the side times 1.4142.
| Rectangle | Diagonal |
|---|---|
| 10 × 10 ft | 14′ 1 11/16″ |
| 10 × 12 ft | 15′ 7 7/16″ |
| 12 × 12 ft | 16′ 11 5/8″ |
| 12 × 16 ft | 20′ |
| 16 × 20 ft | 25′ 7 3/8″ |
| 20 × 24 ft | 31′ 2 7/8″ |
| 24 × 24 ft | 33′ 11 5/16″ |
| 24 × 32 ft | 40′ |
| 28 × 40 ft | 48′ 9 15/16″ |
| 30 × 40 ft | 50′ |
| Side | Diagonal |
|---|---|
| 4 ft | 5′ 7 7/8″ |
| 6 ft | 8′ 5 13/16″ |
| 8 ft | 11′ 3 3/4″ |
| 10 ft | 14′ 1 11/16″ |
| 12 ft | 16′ 11 5/8″ |
| 16 ft | 22′ 7 1/2″ |
| 20 ft | 28′ 3 7/16″ |
A 3-4-5 triangle calculator only has to multiply. The 345 triangle scales up to 6-8-10, 9-12-15 and beyond, and every multiple is still a right triangle. Go as big as the layout allows: the same tape error that hides on a 5 ft check shows up plainly on a 20 ft one.
| Base unit | Sides (3k · 4k · 5k) |
|---|---|
| 1 ft | 3′ · 4′ · 5′ |
| 2 ft | 6′ · 8′ · 10′ |
| 3 ft | 9′ · 12′ · 15′ |
| 4 ft | 12′ · 16′ · 20′ |
| 5 ft | 15′ · 20′ · 25′ |
| 10 ft | 30′ · 40′ · 50′ |
Squaring a layout is geometry, not a code section. Foundations still have to land on the dimensions in the drawings, and a deck ledger has to be square to the house if the joists are to run parallel to it.
Check both diagonals of a rectangle. Equal diagonals plus equal opposite sides is the practical field test, because a single 3-4-5 check squares only one corner. Tape sag, a crown in a batter board, and measuring to the wrong face of a form board will beat a perfect formula, so measure to the same face all the way round.
Section numbers refer to IRC 2021 section numbers; England Approved Document K. Local amendments are common, so confirm with your building authority.
Hover a question to read the answer. Click to keep it open.Tap a question to open it.
From the corner, measure 3 units along one side and 4 units along the other. The straight line between those marks is 5 units when the corner is square. Any multiple works: 6-8-10, 9-12-15 or 12-16-20. Go longer for accuracy, because a small tape error is a smaller angle over a longer check.
20 feet exactly. 12-16-20 is a 3-4-5 triangle scaled by 4. If your measured diagonal is 20 feet, the layout is square to within the accuracy of the tape.
Square each side, add the two results and take the square root: the diagonal is √(a² + b²). For a 12 by 16 ft rectangle that is √(144 + 256) = √400 = 20 ft. Type the two sides into the calculator and it returns the diagonal in feet and inches or in metres.
Multiply the side by √2, about 1.4142. A 10 ft square has a diagonal of 14′ 1 11/16″. It is the same formula with both sides equal, so enter the same number for both sides in the calculator.
The default tolerance here is ⅛ inch (3 mm). Tape sag grows with distance, so many crews allow a little more on a long diagonal than a short one. Type in the tolerance you can live with and compare it with the diagonal you measured. Check both diagonals: two matching diagonals confirm all four corners at once, while a parallelogram can have equal opposite sides and still not be square.
Yes. If the base unit is k, the sides are 3k, 4k and 5k in any unit, because the theorem does not depend on it. Pick the longest multiple that still fits on the two walls you can reach: a 12-16-20 check beats a 3-4-5 check with a short tape. Switch the header to metric and the ratio is 3 m, 4 m, 5 m, or any other base unit you type.
The 3-4-5 method needs only a tape. Mark 3 feet along one side from the corner and 4 feet along the other. Measure between the marks: it should read exactly 5 feet. If it does not, move the second mark until it does. For a bigger, more accurate layout use 6-8-10 or 9-12-15, then check that both diagonals of the finished rectangle match.
Use the house wall as one side. Mark 3 feet along the wall from the corner and 4 feet out along the deck edge, and the line between the marks should read 5 feet. Use 6, 8 and 10 feet for a more accurate check. Adjust the edge until it does, then pull both diagonals of the finished frame.