Foundation Squaring Calculator

Set a building out square — the diagonal to measure, the 3-4-5 check, and how far to move a corner that is off.

How to use this calculator

  1. Enter the two side dimensions to get the diagonal that makes the rectangle square.
  2. Use the 3-4-5 multiple to check a single corner before the whole layout goes in.
  3. Switch to check mode to enter two measured diagonals and see how far out you are.
  4. Move the corners on the longer diagonal by half the difference, then re-measure.

How the calculation works

Setting a building out square is the first measurement on any job and the one every later trade inherits. The geometry is Pythagoras: in a rectangle whose sides are correct, the diagonal is fixed at √(length² + width²), and both diagonals are equal. Measure them, make them match, and the layout is square — no angles, no instruments.

This calculator gives the target diagonal for any rectangle, scales the 3-4-5 triangle for checking an individual corner, and — in check mode — takes two diagonals you have actually measured and tells you how far each corner needs to move.

  • Diagonald = √(length² + width²)
  • 3-4-5 checklegs 3n and 4n → hypotenuse 5n
  • Out of squaredifference between measured diagonals
  • Correctionmove each corner on the long diagonal by difference ÷ 2

Why equal diagonals prove square

A four-sided shape with correct side lengths can still lean into a parallelogram — and when it does, one diagonal grows while the other shrinks. They are equal only in the position where every corner is 90°. That is why one tape measure and two readings beat any framing square: it checks the whole layout at once, not one corner.

The 3-4-5 rule, and why to scale it up

A triangle with sides 3, 4 and 5 has a right angle between the 3 and 4 sides — the smallest whole-number case of Pythagoras. It works at any multiple: 6-8-10, 9-12-15, 12-16-20. Bigger is better, because a fixed measuring error is a smaller proportion of a longer leg. On a house foundation, 12-16-20 finds errors that 3-4-5 hides.

Fixing a layout that is out

When the diagonals differ, half the difference is the correction — because moving a corner shortens one diagonal and lengthens the other simultaneously. Shift the two corners on the LONGER diagonal inward by half the difference, keeping side lengths unchanged, then measure again. Two rounds normally settles it.

How square is square enough

Within 1/8 inch across a full diagonal is the working standard for residential foundations; up to 1/4 inch is usually tolerable. Beyond that the error passes down the whole build — walls out of plumb, floor sheets that will not lie square, cabinet runs with tapering gaps at the end. Getting it right at string-line stage costs minutes; correcting it after a pour costs a great deal more.

Worked examples

A 40 × 24 ft foundation

Setting out a rectangular house footprint with string lines.

Squares
40² = 1,600; 24² = 576
Sum
2,176
Diagonal
√2,176 = 46.65 ft
In feet and inches
46 ft 7 3/4 in

Both diagonals must read 46.65 ft

Set the sides first, then adjust the corners until both diagonals hit that figure. A 3× check — 9 ft and 12 ft legs, 15 ft across — confirms an individual corner before the full layout.

A 12 × 16 ft shed pad

Squaring a small pad before forming.

Squares
16² = 256; 12² = 144
Sum
400
Diagonal
√400 = 20.00 ft exactly
2× check
6 ft, 8 ft → 10 ft

Exactly 20 ft — a 3-4-5 rectangle at 4×

A 12 × 16 pad is a scaled 3-4-5 triangle doubled, so the diagonal lands on a whole number. Worth choosing dimensions like this deliberately when you can.

Diagonals that disagree

A 40 × 24 layout measuring 46.65 ft one way and 46.40 ft the other.

Difference
46.65 − 46.40 = 0.25 ft
In inches
3.00 in out of square
Correction
3.00 ÷ 2 = 1.50 in per corner
Direction
Move the LONG diagonal’s corners in

Shift two corners 1.5 in, then re-measure

Keep the side lengths fixed while you do it — sliding a corner along its own side length is the whole trick. Re-measure both diagonals after every adjustment.

Reference tables

Diagonals for common rectangles

Both diagonals should match these figures when square.

SizeDiagonal (ft)Feet and inches
8 × 1012.8112 ft 9 11/16 in
12 × 1620.0020 ft 0 in
16 × 2025.6125 ft 7 3/8 in
20 × 3036.0636 ft 0 11/16 in
24 × 4046.6546 ft 7 3/4 in
30 × 5058.3158 ft 3 11/16 in

3-4-5 at useful multiples

MultipleLeg ALeg BHypotenuse
3 ft4 ft5 ft
6 ft8 ft10 ft
9 ft12 ft15 ft
12 ft16 ft20 ft
15 ft20 ft25 ft

What it costs

Squaring costs nothing but time, and skipping it costs more than almost any other shortcut on a build. The tools are a long tape, string, batter boards and stakes — under $100 for a set that will square every project you ever lay out.

What the errors cost downstream

An out-of-square foundation is inherited by the framing, which is inherited by the roof, the floors, the drywall and the cabinets. Each trade either absorbs the error with extra labour or passes it on visibly. A half-inch at the foundation is a gap you can see at the end of a cabinet run.

The tools worth having

A 100 ft tape rather than a 25 ft one — measuring a long diagonal in stages introduces exactly the error you are hunting. Batter boards set back from the corners so strings can move without disturbing the stakes. A line level or a laser if the ground falls away, since a diagonal measured across a slope reads long.

When to hire a surveyor

For anything close to a setback line, an easement, or where the plot boundary itself is uncertain, a surveyor at $400–$1,000 is insurance rather than expense. Squaring a layout is a DIY task; knowing precisely where the property line runs often is not.

Common mistakes

Measuring the diagonal across sloping ground

A tape following the ground over a fall reads longer than the true horizontal distance, and the layout ends up out of square in a way the arithmetic never reveals. Measure level — strings at a constant height, not tape on dirt.

Adjusting a corner and stopping there

Moving one corner changes both diagonals. Always re-measure both after any adjustment; the first correction usually gets close rather than exact.

Trusting one corner because it read square

A single 90° corner says nothing about the other three. The diagonal check is a whole-rectangle test, which is why it is the one that matters.

Squaring to the existing building

When adding on, people set the new layout parallel to the old wall — and inherit whatever the old wall was out by. Square the new work to itself, then decide how to reconcile the joint deliberately.

Frequently asked questions

How do I square a foundation?

Set out the sides to the right lengths, then measure both diagonals. When the two diagonals are equal, the rectangle is square — no protractor needed. For a 40 × 24 ft foundation the diagonal is 46.65 ft, or 46 ft 7 3/4 in.

What is the 3-4-5 method?

A right triangle with sides 3, 4 and 5 units is exactly square at the corner between the 3 and 4 sides. Mark 3 ft along one string and 4 ft along the other from the corner; when the marks are 5 ft apart, the corner is 90°. Scale it up — 9-12-15 or 12-16-20 — because a bigger triangle makes small errors more visible.

How square does a foundation need to be?

Within about 1/8 inch across the full diagonal is the practical standard for residential work, and 1/4 inch is generally tolerable. Beyond that, every trade downstream inherits the error — walls out of plumb, floors that will not lay square, cabinets with tapering gaps.

My diagonals are different — how do I fix it?

Divide the difference by two and move the two corners on the LONGER diagonal inward by that amount, keeping the side lengths unchanged. Re-measure both diagonals. One or two rounds of this normally brings a layout square.

Related calculators

Put this calculator on your site

Embed the Foundation Squaring Calculator anywhere — it is free, stays in sync with this page, and sizes itself to fit. The only condition is the credit line in the snippet, which links your readers to the full version with the formulas and worked examples.

<!-- Foundation Squaring Calculator — free embed from BuildCalculators.com -->
<div data-buildcalculators="foundation-squaring-calculator"></div>
<script async src="https://buildcalculators.com/embed.js"></script>
<p>Free foundation squaring calculator by <a href="https://buildcalculators.com/foundation-squaring-calculator">BuildCalculators</a></p>

How this number was worked out

This calculator uses published constants from named industry sources, each asserted in an automated test that runs on every build. The formula is printed with the result above, and any correction we make is logged on the changelog.

It is a planning estimate. It does not replace an engineer, a site visit or a written quote — confirm quantities with your supplier before ordering.