Estimate solar energy production for a site using the NLR (formerly NREL) PVWatts API
domain: developer.nlr.gov · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗
Steps
Obtain a free API key by registering at developer.nlr.gov; the key is passed as the 'api_key' query parameter. (The former developer.nrel.gov domain was retired May 29, 2026 with no redirect — only the hostname changed, existing keys continue to work.)
Make a GET request to https://developer.nlr.gov/api/pvwatts/v8.json with the required parameters: api_key, system_capacity (kW DC), module_type, losses, array_type, tilt, azimuth, and either lat/lon or a file_id identifying a specific climate data file — none of these have a default value, all must be explicitly supplied.
Review the 'outputs' object in the JSON response; key fields include 'ac_annual' (annual AC energy in kWh), 'ac_monthly' (array of 12 monthly values), and 'solrad_annual' (average daily solar radiation).
Set 'losses' (system losses, percent) to reflect site-specific factors like soiling, shading, or wiring losses; the API has no built-in default for this value, so you must pass an explicit number — this parameter significantly affects modeled output.
For time-series hourly output, add the 'timeframe=hourly' parameter; the response will include an 'ac' array of 8760 hourly AC power values in watts, along with matching hourly poa, dc, dn, df, tamb, tcell, wspd, and alb arrays.
Known gotchas
PVWatts uses the nearest TMY (Typical Meteorological Year) weather station, which may not represent a site with unusual microclimates; the response includes 'station_info' showing which station was used — verify it is geographically reasonable.
'array_type' selects the mounting/tracking geometry, not a loss factor — its values are 0 = Fixed Open Rack, 1 = Fixed Roof Mounted, 2 = 1-Axis, 3 = 1-Axis Backtracking, and 4 = 2-Axis. 'tilt' and 'azimuth' are separate required parameters with no default (there is no implicit 'latitude tilt, 180°' fallback); mismatching array_type with the actual physical mounting changes the irradiance/tracking model used and will skew the production estimate.
DC system capacity is the nameplate rating; the API applies the dc_ac_ratio (default 1.2) internally — avoid manually dividing by dc_ac_ratio to convert; instead, pass the correct DC capacity and let the API handle the ratio.
Give your agent this knowledge — and 15,500+ more routes
One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp
Need this verified for your stack — or a route we don't have yet?