Green Planet Energy

The Green Planet Energy integrationIntegrations connect and integrate Home Assistant with your devices, services, and more. [Learn more] provides real-time electricity pricing data from Green Planet Energy, a German renewable energy provider. It fetches 15-minute electricity prices and exposes various sensors for energy monitoring and optimization. Use it to shift your power consumption to cheaper hours and make the most of a dynamic electricity tariff.

Prerequisites

You don’t need an account with Green Planet Energy to set up this integration. However, it is most useful if you are a customer with a dynamic electricity tariff. No credentials are required during setup.

Configuration

To add the Green Planet Energy service to your Home Assistant instance, use this My button:

Manual configuration steps

If the above My button doesn’t work, you can also perform the following steps manually:

  • Browse to your Home Assistant instance.

  • Go to Settings > Devices & services.

  • In the bottom right corner, select the Add Integration button.

  • From the list, select Green Planet Energy.

  • Follow the instructions on screen to complete the setup.

Supported functionality

Entities

The Green Planet Energy integration provides the following sensor entities.

Sensors

  • Current price: The current electricity price in EUR/kWh.
  • Highest price today: The highest electricity price for the current day in EUR/kWh.
  • Highest price time: The timestamp when today’s highest price occurs.
  • Lowest price day (06:00-18:00): The lowest electricity price during daytime hours in EUR/kWh.
  • Lowest price day time (06:00-18:00): The timestamp when the lowest daytime price occurs.
  • Lowest price night (18:00-06:00): The lowest electricity price during nighttime hours in EUR/kWh.
  • Lowest price night time (18:00-06:00): The timestamp when the lowest nighttime price occurs.

List of actions

The Green Planet Energy integrationIntegrations connect and integrate Home Assistant with your devices, services, and more. [Learn more] provides the following actions. Each link below opens a dedicated page with examples, parameters, and a step-by-step UI walkthrough.

  • Get cheapest time window (green_planet_energy.get_cheapest_duration) Find the cheapest time window for a given duration in the selected time range.

  • Get energy prices (green_planet_energy.get_prices) Fetches upcoming 15-minute electricity price slots from Green Planet Energy.

For an overview of every action across all integrations, see the actions reference.

Examples

Show upcoming prices as a chart

You can use the Get energy prices action together with a template sensor to create a sensor that holds the upcoming price data as an attribute. This makes it easy to display a price chart on your dashboard.

Add the following to your configuration.yamlThe configuration.yaml file is the main configuration file for Home Assistant. It lists the integrations to be loaded and their specific configurations. In some cases, the configuration needs to be edited manually directly in the configuration.yaml file. Most integrations can be configured in the UI. [Learn more] file: After changing the configuration.yamlThe configuration.yaml file is the main configuration file for Home Assistant. It lists the integrations to be loaded and their specific configurations. In some cases, the configuration needs to be edited manually directly in the configuration.yaml file. Most integrations can be configured in the UI. [Learn more] file, restart Home Assistant to apply the changes. The integration is now shown on the integrations page under Settings > Devices & services. Its entities are listed on the integration card itself and on the Entities tab.

template:
  - triggers:
      - trigger: time_pattern
        minutes: "/15"
    actions:
      - action: green_planet_energy.get_prices
        data:
          config_entry_id: 1234567890abcdef1234567890abcdef
          hours: 6
        response_variable: result
    sensor:
      - name: "Green Planet Energy next 6 hours"
        state: "{{ result.prices | length }}"
        unit_of_measurement: "slots"
        attributes:
          prices: "{{ result.prices }}"
          hours_requested: "{{ result.hours_requested }}"

Find the cheapest time for your dishwasher

Your dishwasher needs 3.5 hours to run. This example shows how to create sensors that display when the cheapest 3.5-hour window occurs during the night.

Add the following to your configuration.yamlThe configuration.yaml file is the main configuration file for Home Assistant. It lists the integrations to be loaded and their specific configurations. In some cases, the configuration needs to be edited manually directly in the configuration.yaml file. Most integrations can be configured in the UI. [Learn more] file: After changing the configuration.yamlThe configuration.yaml file is the main configuration file for Home Assistant. It lists the integrations to be loaded and their specific configurations. In some cases, the configuration needs to be edited manually directly in the configuration.yaml file. Most integrations can be configured in the UI. [Learn more] file, restart Home Assistant to apply the changes. The integration is now shown on the integrations page under Settings > Devices & services. Its entities are listed on the integration card itself and on the Entities tab.

template:
  - triggers:
      - trigger: time_pattern
        hours: "*"
    actions:
      - action: green_planet_energy.get_cheapest_duration
        data:
          duration: 3.5
          time_range: night
        response_variable: cheapest
    sensor:
      - name: "Cheapest 3.5-hour start time"
        state: "{{ cheapest.start_time }}"
        device_class: timestamp
        attributes:
          average_price: "{{ cheapest.average_price }}"
          hours_until_start: "{{ cheapest.hours_until_start }}"
          duration: "{{ cheapest.duration }}"
          time_range: "{{ cheapest.time_range }}"

      - name: "Cheapest 3.5-hour time until start"
        state: "{{ cheapest.hours_until_start }}"
        unit_of_measurement: "h"
        state_class: measurement

      - name: "Cheapest 3.5-hour average price"
        state: "{{ cheapest.average_price }}"
        unit_of_measurement: "€/kWh"
        state_class: measurement

This creates three sensors:

  • sensor.cheapest_3_5_hour_start_time: Shows when to start your dishwasher.
  • sensor.cheapest_3_5_hour_time_until_start: Shows how many hours until that moment.
  • sensor.cheapest_3_5_hour_average_price: Shows the average price during that window.

Known limitations

Prices are published for today and tomorrow only. If you ask for more hours than that, the slots without data are left out of the Get energy prices response instead of returned as zero.

Removing the integration

This integration follows standard integration removal.

To remove an integration instance from Home Assistant

  1. Go to Settings > Devices & services and select the integration card.
  2. From the list of devices, select the integration instance you want to remove.
  3. Next to the entry, select the three dots menu. Then, select Delete.

Disclaimer

This integration is a third-party community project and is not affiliated with or endorsed by Green Planet Energy eG.