function calculateConcrete() {
// 1. Get input values
var length = parseFloat(document.getElementById('slabLength').value);
var width = parseFloat(document.getElementById('slabWidth').value);
var thickInches = parseFloat(document.getElementById('slabThickness').value);
var wastePercent = parseFloat(document.getElementById('wasteFactor').value);
// 2. Validate inputs
if (isNaN(length) || isNaN(width) || length <= 0 || width <= 0) {
alert("Please enter valid positive numbers for Length and Width.");
return;
}
// 3. Perform Calculations
// Convert thickness to feet
var thickFeet = thickInches / 12;
// Calculate cubic feet (L * W * T)
var cubicFeet = length * width * thickFeet;
// Add waste margin
var totalCubicFeet = cubicFeet * (1 + (wastePercent / 100));
// Convert to Cubic Yards (1 Yard = 27 Cubic Feet)
var cubicYards = totalCubicFeet / 27;
// Calculate Bags (Standard concrete density approx 133-150 lbs/ft³, using 150 safe est for wet concrete calculation or premix yield)
// Standard Yield: One 80lb bag yields approx 0.60 cubic feet
// Standard Yield: One 60lb bag yields approx 0.45 cubic feet
// Using volume yield formula for bags is more accurate than weight for pre-mix:
var bags80 = totalCubicFeet / 0.60;
var bags60 = totalCubicFeet / 0.45;
// 4. Update UI
document.getElementById('resYards').innerHTML = cubicYards.toFixed(2);
document.getElementById('resFeet').innerHTML = totalCubicFeet.toFixed(2) + " ft³";
document.getElementById('res80lb').innerHTML = Math.ceil(bags80) + " Bags";
document.getElementById('res60lb').innerHTML = Math.ceil(bags60) + " Bags";
// Show results
document.getElementById('resultsArea').style.display = 'block';
}
How to Calculate Concrete for Your Project
Planning a new patio, driveway, or walkway? Calculating the exact amount of concrete required is the most critical step in the planning process. Ordering too little can result in catastrophic "cold joints" (structural weaknesses where fresh concrete meets hardened concrete), while ordering too much is a waste of money and resources. Our Concrete Slab Calculator uses standard industry formulas to help you estimate your materials accurately.
The Concrete Formula Explained
Concrete is measured by volume, specifically in Cubic Yards. To calculate this manually, you need to determine the volume of your slab in cubic feet and then convert it.
The math follows three simple steps:
Step 1: Convert your slab thickness from inches to feet (divide by 12).
Step 2: Multiply Length × Width × Thickness (in feet) to get Cubic Feet.
Step 3: Divide Cubic Feet by 27 to get Cubic Yards.
Example: A 10′ x 10′ patio that is 4 inches thick would be: 10 × 10 × 0.33 = 33 cubic feet. Divide 33 by 27 to get 1.22 Cubic Yards.
Recommended Thickness Guidelines
Not sure how thick your slab needs to be? Use these general industry standards:
4 Inches: Standard for residential sidewalks, garden paths, and patio slabs used for foot traffic and patio furniture.
5-6 Inches: Required for driveways, garage floors, or areas that will hold hot tubs or light machinery.
8+ Inches: Necessary for heavy equipment loads, RV pads, or industrial foundations.
Pre-Mix Bags vs. Ready Mix Truck
Once you have your calculation, you must decide how to buy the concrete.
Use Pre-Mix Bags (60lb or 80lb) if you need less than 1.0 cubic yard of concrete. This is feasible for DIY mixing in a wheelbarrow or portable mixer.
Order a Ready Mix Truck if your project requires more than 1.0 to 1.5 cubic yards. Mixing this volume by hand is extremely physically demanding and time-sensitive. Standard ready-mix trucks hold between 8 to 10 cubic yards.
Why Add a Waste Factor?
Professional contractors always add a "waste" or "spillage" margin, typically 5% to 10%. This accounts for:
Uneven sub-grade (dips in the ground)
Spillage during transport
Form bowing (wooden forms bending outward under pressure)
It is always cheaper to buy a few extra bags or order slightly more yardage than to pay for a "short load" fee for a second delivery.