skillfed

forecast-solar

Asynchronous Python client for getting forecast solar information

forecast-solar v5.0.1 74.6K downloads/30d#14,818 on PyPI32
Permissive license MIT Active released

What it is and what it does

forecast-solar is an async Python wrapper around the forecast.solar API that retrieves solar panel production forecasts for specific geographic locations and panel configurations. It returns energy production estimates (in kWh) for various time windows—today, tomorrow, this hour, next hour, and remaining daylight—along with power output predictions (in watts) at multiple future intervals and peak timing information.

The library is designed for integration with home automation systems and energy management applications. It supports single or multiple solar panel planes (with appropriate subscription), accepts panel configuration parameters like tilt angle (declination), direction (azimuth), and capacity (kWp), and provides optional damping factors to account for weather variability. All API calls are asynchronous, making it suitable for non-blocking integration into event-driven applications.

Use it for:

  • Home automation systems that adjust energy consumption based on predicted solar output.
  • Energy management dashboards displaying hourly and daily solar production forecasts.
  • Battery charging optimization that schedules charging during predicted peak solar production hours.
  • Grid-tied solar systems that need to forecast excess production for export planning.
  • Renewable energy monitoring applications tracking multiple roof-facing solar arrays.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Asynchronous Python client for fetching solar panel energy and power production forecasts from the forecast.solar API, including hourly estimates and peak timing data.

Yes, if you have solar panels and need programmatic access to production forecasts. The package is actively maintained, has low install friction, and integrates cleanly with async Python applications. Requires a forecast.solar API key (free tier available) and Python 3.12+; some advanced features require a paid subscription.

Install

forecast-solar on PyPI

pip

pip install forecast-solar

uv

uv add forecast-solar

poetry

poetry add forecast-solar

Installing forecast-solar

Before you install

Low install friction with only two lightweight runtime dependencies (aiohttp and yarl). Active maintenance with recent release (69 days ago) and ongoing commits; supports modern Python versions (3.12, 3.13, 3.14).

License in practice

MIT license permits unrestricted use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects.

Quickstart

import asyncio
from forecast_solar import ForecastSolar

async def main():
    async with ForecastSolar(
        api_key="YOUR_API_KEY",
        latitude=52.16,
        longitude=4.47,
        declination=20,
        azimuth=10,
        kwp=2.160
    ) as forecast:
        estimate = await forecast.estimate()
        print(estimate)

asyncio.run(main())

Requires an API key from forecast.solar; some features (multiple planes) require a Personal Plus subscription or higher.

Verify before relying

  • Whether free tier API access provides sufficient rate limits for typical use cases.
  • Accuracy of forecasts under various weather conditions and geographic regions.
  • Performance characteristics when querying multiple planes simultaneously.

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.12)
Install friction low — pure-Python wheel
Runtime dependencies 2 — aiohttp, yarl
Maintenance actively maintained — 69 days since the last release
Last repo commit
First released
Downloads 74,555/month — #14,818 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: forecast_solar-5.0.1-py3-none-any.whl

Keywords: forecast, solar, power, energy, api, async, client

Framework :: AsyncIOIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseNatural Language :: EnglishProgramming Language :: Python :: 3Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Software Development :: Libraries :: Python Modules

Tags

solar forecast api clientsolar panel energy predictionasync solar power forecastforecast.solar python librarysolar production estimationrenewable energy forecastingsolar irradiance prediction
solar-energyasync-http-clienthome-automation

More Python Modules packages