SmartGridready Dynamic Tariff

SmartGridready Dynamic Tariff — Home Assistant integration for Swiss dynamic tariffs (BKW feed-in + any VSE/SmartGridready-conformant provider)

Sharing a custom integration I built for dynamic electricity tariffs following the Swiss VSE / SmartGridready OpenAPI spec (“Dynamische Netznutzungstarife im Verteilnetz”, valid from 2026).

It works out of the box with BKW’s dynamic feed-in remuneration (Abnahmevergütung), and should work with any provider that publishes a spec-conformant API — see the SmartGridready tariff map for other providers.

What it gives you

  • GUI setup — no YAML. Add multiple tariff sources as separate entries (e.g. today’s BKW feed-in price, later a consumption tariff too).

  • Dynamic Tariff sensor — current price, updated exactly on every quarter-hour slot boundary, with today/tomorrow forecast arrays and min/max/average attributes for charts and automations.

  • Export value rate — optional: point it at your inverter’s power sensor (with an invert flag for sign convention) and it computes your live CHF/h earning rate natively, no manual templates needed.

  • Max price today, plus dedicated Max price start / Max price end timestamp sensors — usable directly as at: targets in a time trigger, so you can schedule battery discharge, EV charging, etc. right at the price peak without any template math.

  • Handles the awkward provider behavior where the evening publication only returns tomorrow’s prices — slots are merged into a cache (now persisted to disk, so a restart between the evening publication and midnight doesn’t lose the rest of today).

  • Optional VAT factor and fixed surcharge per source, changeable later via the entry’s Configure dialog.

Example automation

Trigger right at the daily price peak, no templating required:

trigger:
  - platform: time
    at: sensor.dynamic_tariff_max_price_start

Screenshot

device page showing the Dynamic Tariff, Export value rate, Max price today/start/end sensors

Install

Via HACS as a custom repository (not in the default store yet):

  1. HACS → Integrations → ⋮ → Custom repositories → add https://github.com/14yannick/sgr_dyntariff (category: Integration)
  2. Install, restart HA
  3. Settings → Devices & Services → Add integrationSmartGridready Dynamic Tariff

Repo / docs / issues: GitHub - 14yannick/sgr_dyntariff: Home Assistant integration for Swiss dynamic electricity tariffs (VSE/SmartGridready API) – BKW feed-in remuneration and other conform providers · GitHub

Feedback, bug reports, and PRs adding other conformant provider URLs (there’s a table in the README) are very welcome!

1 Like