Rainwater Harvesting Calculator Formula

Understand the math behind the rainwater harvesting calculator. Each variable explained with a worked example.

Formulas Used

Annual Rainwater Collected

gallons_collected = annual_gallons

Monthly Average

monthly_avg = annual_gallons / 12

Annual Water Savings

annual_savings = annual_gallons * water_cost / 1000

Recommended Tank Size

tank_size = ceil(annual_gallons / 12 / 100) * 100

Variables

VariableDescriptionDefault
roof_sqftCollection Roof Area(sq ft)1500
annual_rainfall_inAnnual Rainfall(inches)40
collection_efficiencyCollection Efficiency(%)80
water_costMunicipal Water Cost(USD/1000 gal)5
annual_gallonsDerived value= roof_sqft * annual_rainfall_in * 0.623 * collection_efficiency / 100calculated

How It Works

How to Calculate Rainwater Collection

Rainwater harvesting captures roof runoff for irrigation, toilet flushing, or other non-potable uses.

Formula

Gallons = Roof Area (sq ft) * Rainfall (inches) * 0.623 * Collection Efficiency

The factor 0.623 converts 1 inch of rain on 1 sq ft to gallons. Efficiency accounts for gutter losses, first-flush diversion, and evaporation.

Worked Example

1,500 sq ft roof in an area with 40 inches annual rainfall, 80% collection efficiency, $5/1000 gal water cost.

roof_sqft = 1500annual_rainfall_in = 40collection_efficiency = 80water_cost = 5
  1. 01Annual collection: 1,500 * 40 * 0.623 * 0.80 = 29,904 gallons
  2. 02Monthly average: 29,904 / 12 = 2,492 gallons
  3. 03Annual savings: 29,904 * $5 / 1,000 = $150
  4. 04Recommended tank: ceil(2,492 / 100) * 100 = 2,500 gallons

Ready to run the numbers?

Open Rainwater Harvesting Calculator