Push your PV system data (grid power, solar production, battery status) to the clever-PV Push API and receive battery control instructions if needed.
- Push data to clever-PV (grid power, solar production, battery status)
- Optional battery control: receive charging/discharging instructions from clever-PV
- Supports grid power, solar production, battery SOC, and charging power
- Configurable push interval (10-300 seconds, default 30)
- Various sensors to monitor push status and battery control state
- Open HACS in Home Assistant
- Click the three dots in the top right corner
- Select "Custom repositories"
- Add
https://github.com/clever-PV/home-assistant-clever-PVwith category "Integration" - Click "Add"
- Search for "clever-PV" and install it
- Restart Home Assistant
- Go to "Settings"->"Integrations"-Tab
- Click "+ Add Integration button"
- Search for clever-PV and add it.
- Follow the setup flow
- Copy the
custom_components/cleverpvfolder to your Home Assistant'sconfig/custom_components/directory - Restart Home Assistant
- Add a Push API device according to this tutorial: https://support.clever-pv.com/hc/de/articles/22801081762066-Push-API
- Optional: Enable AI Battery Control
- Go to Settings > Devices & Services
- Click Add Integration
- Search for "clever-PV"
- Enter your clever-PV Push URL (from your clever-PV account)
- Select the entities to push:
- Grid Power (required): Sensor showing grid power in watts (positive = import, negative = export)
- Solar Production (optional): Sensor showing current solar production in watts
- Battery SOC (optional): Sensor showing battery state of charge in percent
- Battery Power (optional): Sensor showing battery charging/discharging power in watts
- Configure optional features:
- Enable Battery Control (optional): When enabled, clever-PV can send battery control instructions back to Home Assistant
The integration creates the following diagnostic sensors:
| Sensor | Description |
|---|---|
| Push Status | Success or error status of the last push |
| Last Push | Timestamp of the last successful push |
| Last Response | Response message from the clever-PV API |
| Last Payload | JSON payload of the last push |
| Push Count | Total number of successful pushes |
When Battery Control is enabled, additional sensors are created:
| Sensor | Description |
|---|---|
| Battery Control State | Current instruction from clever-PV: Normal, Idle, Force Charge, Force Discharge, or Limit Charge Power |
| Battery Force Power | Target power in watts (only set for Force Charge/Discharge) |
The integration sends the following data to clever-PV:
| Field | Description |
|---|---|
watt |
Grid power (positive = import, negative = export) |
producingWatt |
Solar production in watts |
soc |
Battery state of charge (0-100%) |
chargingPower |
Battery power in watts |
powerStorageState |
0=idle, 1=charging, 2=disabled, 3=discharging |
batteryControlEnabled |
When true, requests battery control instructions |
When battery control is enabled, clever-PV can send instructions to optimize your battery based on electricity prices and solar forecast. These instructions will be held in two sensors:
Battery Control State: Normal, Idle, Force Charge, Force Discharge, or Limit Charge PowerBattery Force Power: Desired Power for your battery not in Idle or Normal mode
Battery control requires:
- A clever-PV account with Smart Battery Price Control enabled
- A dynamic electricity tariff configured in clever-PV
- The integration sends
batteryControlEnabled: truewith each push - clever-PV responds with battery control instructions (if available)
- The instructions appear as sensor values in Home Assistant
| State | Description |
|---|---|
| Normal | Self-consumption mode (default behavior) |
| Idle | Pause charging and discharging |
| Force Charge | Charge battery at specified power |
| Force Discharge | Discharge battery at specified power |
| Limit Charge Power | Self-consumption with limited charging |
You can use the battery control sensors in Home Assistant automations to control your battery inverter. For example, create an automation that reads the Battery Control State sensor and sends the appropriate command to your inverter.
To change settings after initial setup:
- Go to Settings > Devices & Services
- Find the clever-PV integration
- Click Configure
- Update the Push URL or entity selections
Enable debug logging by adding to configuration.yaml:
logger:
default: info
logs:
custom_components.cleverpv: debugThis project is licensed under the MIT License - see the LICENSE file for details.