Roof Size & Pitch Estimator web app based on Google Geocoding + Google Solar APIs.
- Address input
- Geocoding to lat/lng
- Solar
buildingInsights:findClosestwithHIGHthenMEDIUMfallback - Roof area output in m² and sq ft
- Roofing squares
- Representative pitch (area-weighted) in degrees and x:12
- Optional segment table
- Google Static Map target-house image
- ChatGPT vision roof analysis (outline + ridges + measurement line-items)
- Server-side API key protection
POST /api/roof-estimate
Request:
{ "address": "21106 Kenswick Meadows Ct, Humble, TX 77338" }Prerequisites for your Google Cloud key:
- Geocoding API enabled
- Solar API enabled
- Static Maps API enabled
Additional AI analysis config:
OPENAI_API_KEY: API key for OpenAI Responses API- Optional:
OPENAI_ROOF_MODEL(defaultgpt-5)
- Copy env file:
cp .env.example .env.local- Set your key:
GOOGLE_MAPS_API_KEY=your_google_api_key
- Install and run:
npm install
npm run devOpen http://localhost:3000.
- This app is an estimator.
- It does not provide ridge/hip/valley/eave/rake/gutter line-item measurements.