Dirt Calculators

Dirt Calculators › Backfill calculator

Backfill calculator

Work out how much dirt it takes to backfill a trench, a hole or the gap around a foundation. Trench widths are often in inches: 6 in is 0.5 ft, 12 in is 1 ft.

What are you filling?

Trench widths are often given in inches: 6 in = 0.5 ft, 12 in = 1 ft, 18 in = 1.5 ft.

Dump truck load card
—loads

Cubic yards—
Cubic feet—
Tons (about)—
Material cost—

How to calculate backfill

backfill (yd³) = (length × width × depth in ft − volume of anything left in the trench) ÷ 27 × (1 + compaction)

Worked example: a utility trench. 50 ft long, 12 inches wide, 3 ft deep, with 15% compaction:

If the pipe is bedded in sand or gravel, subtract the bedding volume from the dirt and order the bedding separately. For example, 6 inches of sand in the bottom of that trench is 50 × 1 × 0.5 = 25 cu ft, or 0.93 yd³ of sand.

Trench volume table

Measured volume per 100 feet of trench, before compaction:

Trench width × depth Cubic feet per 100 ft Cubic yards per 100 ft
6 in × 18 in 75 2.78
6 in × 24 in 100 3.70
12 in × 24 in 200 7.41
12 in × 36 in 300 11.11
18 in × 36 in 450 16.67
24 in × 48 in 800 29.63

Backfilling around a foundation

When a foundation is built, the hole is dug wider than the walls so the crew can work. That gap gets backfilled once the walls are ready.

  1. Measure the length of wall being backfilled (the perimeter, if it is all the way around).
  2. Measure the width of the gap between the wall and the side of the hole. If the sides slope, use the width halfway down.
  3. Measure the depth from the bottom of the gap to finished grade.
  4. Use trench mode: length × gap width × depth.

Example. 140 ft of wall, a 2 ft average gap, 7 ft deep: 140 × 2 × 7 = 1,960 cu ft = 72.6 yd³ measured, about 83.5 yd³ with 15% compaction. Foundation backfill is usually placed and compacted in layers, often with drainage stone against the wall, as the builder or engineer specifies.

Backfilling holes

Backfill tips

Where does backfill come from?

Usually from the trench itself. When you dig, the dirt swells by roughly 20 to 30 percent, so the spoil pile is bigger than the trench. The excavation calculator estimates the pile. If the dug dirt is unsuitable (full of rock, waterlogged clay, or contaminated), you need fill brought in: the fill dirt calculator and fill dirt cost guide help with that order.

Backfill specifications for foundations, septic systems and utilities come from codes, engineers and utility companies. These figures are for estimating quantities, not for deciding what material or compaction a job requires.

Illustration of a trench in cross-section with a pipe on a sand bed and a person shoveling dirt back in

Questions people ask

How do I calculate backfill for a trench?
Multiply trench length × width × depth in feet to get cubic feet, subtract the volume of any pipe and bedding that will stay in the trench if it is large, divide by 27 for cubic yards, and add 15 to 20 percent for compaction.
How do I calculate trench volume?
Length × width × depth, all in feet, gives cubic feet. Divide by 27 for cubic yards. A trench 50 ft long, 1 ft wide and 3 ft deep is 150 cubic feet, or 5.56 cubic yards.
Can I backfill with the dirt I dug out?
Usually yes, as long as it is free of large rocks, roots and debris and the job does not call for a special material. Because dug dirt swells, you normally have a little left over even after compacting it back in.
What is the best backfill around a pipe?
Many pipes are laid on and covered with a bedding of sand or fine gravel first, then the trench is finished with native soil. Follow the pipe maker's or local code requirements for bedding and cover depth.
How do I compact backfill?
Place it in layers, typically 4 to 8 inches thick, and tamp or compact each layer before adding the next. Avoid dumping the whole trench full and compacting only the top.

Related calculators and guides