Extended support for Tibber electricity prices in Home Assistant
  • Python 76.5%
  • JavaScript 20.4%
  • Shell 3.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
renovate[bot] 20d1fba440
Some checks failed
Lint & Test / Ruff, Pyright, pytest (push) Failing after 1s
chore(dev-deps): update dependency zlib_ng to >=1.1.0,<1.2.0 (#249)
2026-11-04 08:21:13 +01:00
.claude feat(settings): add local settings for script permissions 2026-04-25 18:36:02 +00:00
.devcontainer chore(dev-env): manage development tools and Python version with mise 2026-10-25 18:07:48 +00:00
.github chore(dev-deps): update jdx/mise-action action to v5.2.6 (#246) 2026-11-03 08:50:15 +01:00
config fix(cards): make the card windows and strips usable on phones (#223) 2026-10-18 16:40:16 +02:00
custom_components/tibber_prices chore(release): bump version to 0.39.0 2026-11-01 23:51:27 +00:00
docs docs: add version snapshot v0.39.0 and cleanup old versions [skip ci] 2026-11-01 23:53:15 +00:00
examples/scripts docs: add blueprint import badges and update automation examples 2026-04-20 18:45:20 +00:00
images chore: Update logo and icons for Tibber Prices Integration 2025-12-07 19:00:32 +00:00
planning docs: add refactoring guide and planning directory documentation 2025-11-15 12:07:18 +00:00
schemas docs(CONTRIBUTING): improve clarity and formatting in contribution guidelines 2026-04-14 15:35:16 +00:00
scripts ci: run each check only for the files it reads, add pyright, pytest and a PR docs build 2026-11-01 23:44:18 +00:00
tests feat(marketplace): support the built-in Marketplace, rename to Tibber Prices & Planning 2026-11-01 23:29:18 +00:00
.editorconfig chore(dev-deps): replace Dependabot with Renovate 2026-10-25 18:08:02 +00:00
.gitattributes Initial commit 2025-04-18 14:32:54 +02:00
.gitignore chore(dev): add HACS installation and sync scripts for testing 2025-11-16 18:05:14 +00:00
.markdownlint.json docs(CONTRIBUTING): improve clarity and formatting in contribution guidelines 2026-04-14 15:35:16 +00:00
.pre-commit-config.yaml chore(pre-commit): add docusaurus build guard for changed docs sites 2026-04-09 18:41:41 +00:00
.prettierignore chore(dev-env): manage development tools and Python version with mise 2026-10-25 18:07:48 +00:00
.prettierrc.yaml docs(CONTRIBUTING): improve clarity and formatting in contribution guidelines 2026-04-14 15:35:16 +00:00
.python-version chore(dev-env): manage development tools and Python version with mise 2026-10-25 18:07:48 +00:00
AGENTS.md feat(marketplace): support the built-in Marketplace, rename to Tibber Prices & Planning 2026-11-01 23:29:18 +00:00
cliff.toml chore(scripts): improve release tooling with trailer filtering and Impact rendering 2026-04-12 12:11:56 +00:00
CODEOWNERS feat(workflow): add auto-assign GitHub Action for issue assignment 2026-04-12 16:29:33 +00:00
CONTRIBUTING.md docs(CONTRIBUTING): improve clarity and formatting in contribution guidelines 2026-04-14 15:35:16 +00:00
hacs.json feat(marketplace): support the built-in Marketplace, rename to Tibber Prices & Planning 2026-11-01 23:29:18 +00:00
LICENSE Rename component 2025-04-18 12:51:32 +00:00
mise.toml chore(dev-deps): update dependency uv to v0.13.7 (#248) 2026-11-03 08:50:29 +01:00
pyproject.toml chore(dev-env): manage development tools and Python version with mise 2026-10-25 18:07:48 +00:00
README.md docs: use the name Tibber Prices & Planning in titles and the README lead 2026-11-01 23:50:14 +00:00
renovate.json chore(dev-deps): replace Dependabot with Renovate 2026-10-25 18:08:02 +00:00
requirements.txt chore(dev-deps): update dependency zlib_ng to >=1.1.0,<1.2.0 (#249) 2026-11-04 08:21:13 +01:00

Tibber Prices & Planning – Custom Integration for Home Assistant

Tibber Prices & Planning

GitHub Release GitHub Activity License Project Maintenance

Buy Me A Coffee

⚠️ Not affiliated with Tibber This is an independent, community-maintained custom integration for Home Assistant. It is not an official Tibber product and is not affiliated with or endorsed by Tibber AS.

Plan your electricity use around Tibber's quarter-hourly prices. 100+ sensors with price levels and ratings, best and peak price periods, forecasts, trends and volatility, plus scheduling actions, ready-made blueprints and dashboard cards of its own – all from one integration.

📖 Documentation

📚 Complete Documentation — Installation, guides, examples, and full sensor reference:

Quick Links: Installation · Sensor Reference · Dashboard Cards · ApexCharts · Automations · FAQ · Changelog

✨ Why This Integration?

Most Tibber integrations give you a single price sensor. This one gives you a complete energy optimization toolkit:

🔮 Know What's Coming

  • Quarter-hourly precision — 15-minute interval prices, not just hourly averages
  • Price forecasts — See average prices for the next 1h, 2h, 3h, ... up to 12h ahead
  • Trend analysis — Know if prices are rising, falling, or stable — and when the next trend change happens
  • Price trajectory — Detect turning points before they happen (first-half vs second-half window comparison)
  • Price outlook — Instantly see if the next hours will be cheaper or more expensive than now

⚡ Automate Smartly

  • Best Price & Peak Price Periods — Intelligent binary sensors that detect the cheapest and most expensive periods of the day, with configurable flexibility, relaxation strategies, and gap tolerance (how it works)
  • Period timing sensors — Duration, end time, remaining minutes, progress percentage, and countdown to next period — everything you need for advanced automations
  • Runtime configuration — Adjust period detection parameters on the fly via switches and number entities, without restarting — perfect for automations that adapt to your schedule
  • 5-level price classification — VERY_CHEAP, CHEAP, NORMAL, EXPENSIVE, VERY_EXPENSIVE from Tibber's API
  • 3-level price ratings — LOW, NORMAL, HIGH based on 24h trailing average comparison

📊 Visualize Beautifully

  • Dashboard cards of its own — Nothing to install, a visual editor, and you only pick your home: the Forecast Card shows the price now, the coming hours, the parts of the day and today and tomorrow like a weather forecast, with details on every tap; the Now Card puts the price now on today's scale as a tile, a gauge or a 12-hour clock; the Chart Card draws the price curve, read by sliding a cursor across it. They open each other in windows (see the cards)
  • Dynamic icons & colors — Every sensor adapts its icon and color to the current price state — cheap prices glow green, expensive ones turn red (icon guide)
  • Chart data export — Flexible data API with filtering, resolution control, and multiple output formats for any visualization card
  • ApexCharts as an alternative — Already using ApexCharts everywhere? One action call generates complete charts in the same look as your others (see examples)

📈 Understand Your Market

  • Volatility analysis — Know if today's prices are stable or wild (low/moderate/high/very_high)
  • Daily & rolling statistics — Min, max, average, median for today, tomorrow, trailing 24h, and leading 24h
  • Energy & tax breakdown — See spot price vs. tax components as sensor attributes
  • Multi-currency support — EUR, NOK, SEK, DKK, USD, GBP with configurable base/subunit display (€ vs ct, kr vs øre)
  • Time-travel views — Add a second device showing the same home as it was 7 days ago, or on the same date last year. Its clock runs at normal speed, so you can rehearse an automation against a day you already know the outcome of — including the moment tomorrow's prices originally appeared (guide)

🛡️ Built for Reliability

  • Intelligent caching — Multi-layer caching minimizes API calls, survives HA restarts, auto-invalidates at midnight
  • High-performance interval pool — O(1) timestamp lookups, gap detection, auto-fetching of missing data
  • Quarter-hour precision updates — Sensors refresh at :00/:15/:30/:45 boundaries, independent of API polling
  • Official API only — Uses Tibber's priceInfo and priceInfoRange endpoints. All ratings and statistics are calculated locally.

🚀 Quick Start

Step 1: Install from the Marketplace (or HACS)

Home Assistant 2026.11 or newer (built-in Marketplace):

Open your Home Assistant instance and open a repository inside the Marketplace.

Older versions with HACS:

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

  1. Click "Download" to install
  2. With HACS, restart Home Assistant (details)

Step 2: Configure

Open your Home Assistant instance and start setting up a new integration.

  1. Enter your Tibber API token (get one here)
  2. Select your Tibber home
  3. Configure price thresholds (optional — sensible defaults are provided)

Or manually: Settings → Devices & Services → + Add Integration → search "Tibber Prices & Planning"

Step 3: Done!

  • 100+ sensors are now available (key sensors enabled by default, advanced ones ready to enable)
  • Explore entities in Settings → Devices & Services → Tibber Prices & Planning
  • Start building automations, dashboards, and energy-saving workflows

📖 Full Installation Guide →

🧩 Dashboard Cards

The integration brings its own cards. Add them from the card picker, pick your home, done.

Now card as a tile among Home Assistant's tiles, as a gauge on today's scale and as a clock of the coming twelve hours

Now Card — the price now and what to make of it: a best price period running, cheap until, the next best price. As a tile, a gauge or a clock of the coming twelve hours, with the trend in the corner. A tap opens the details, or the whole forecast card in a window.

Forecast card with the price now, the coming hours as bars, the parts of the day as spans, and today and tomorrow

Forecast Card — the coming hours and parts of the day like a weather forecast, in the price level's colors, with best and peak price periods underlined, and today and tomorrow on one scale. Tap any hour, part of the day or day for its details.

Chart card: the price curve in the price level's colors, with the price at the cursor in the line on top

Chart Card — the price curve for the outlook, today, tomorrow or both days, in 15 or 60 minutes. Slide across it (or hold and drag on a phone) to read each price, its level and how far it lies from the average, in a line or a ring on top. Several styles to switch between, including the simple one of Tibber's app.

Cards inside cards — a now tile on your main dashboard opens the whole forecast with a tap and the price chart from a small icon; the editor shows each card held this way one level down, as Home Assistant's own stack cards do.

📖 Dashboard Cards → — every option, the tile feature, and how to read the cards

📊 What You Get

The integration provides 100+ entities across sensors, binary sensors, switches, and number entities. Here are the highlights — all key sensors are enabled by default:

Dashboard with the now card as a gauge, today and tomorrow, the coming hours and parts of the day, and the price chart below

Want this dashboard? The tibber_prices.get_dashboard_yaml action builds it for your home, ready to paste into one of your dashboards: Complete Dashboard as a Starting Point →

Category Highlights Count
💰 Prices Current, next & previous interval price + rolling hour averages 6+
📊 Statistics Daily min/max/avg for today & tomorrow, 24h trailing & leading windows 12+
🔮 Forecasts Next 1h–12h average prices, price outlook & trajectory sensors 20+
📈 Trends Current trend direction, next trend change time & countdown 3
📉 Volatility Today, tomorrow, next 24h & combined volatility levels 4
🏷️ Levels & Ratings 5-level (API) and 3-level (computed) classification per interval, hour & day 12+
⏰ Period Timing Best/peak: end time, duration, remaining, progress, next start 10+
🔌 Binary Sensors Best price period, peak price period, tomorrow data available, API connection 4+
🎛️ Runtime Config Switches & numbers to adjust period detection live — no restart needed 14
🔧 Diagnostics Data lifecycle status, home metadata, grid info, subscription status 15+

Every sensor includes rich attributes — timestamps, detailed descriptions, and context data. Enable Extended Descriptions in the integration options to get long_description and usage_tips on every entity.

📖 Complete Sensor Reference → — All entities with descriptions, attributes, and multi-language lookup

🤖 Automation Sneak Peek

See the full automation examples guide for more recipes.

Run appliances when electricity is cheapest:

automation:
  - alias: "Start Dishwasher During Best Price Period"
    trigger:
      - platform: state
        entity_id: binary_sensor.tibber_best_price_period
        to: "on"
    action:
      - action: switch.turn_on
        target:
          entity_id: switch.dishwasher

Reduce heating when prices spike above average:

automation:
  - alias: "Reduce Heating During High Prices"
    trigger:
      - platform: numeric_state
        entity_id: sensor.tibber_current_interval_price_rating
        above: 20 # More than 20% above 24h average
    action:
      - action: climate.set_temperature
        target:
          entity_id: climate.living_room
        data:
          temperature: 19

📖 More automations → — EV charging, heat pump control, price notifications, and more

📈 ApexCharts as an Alternative

The chart card covers the price curve with nothing to install. If you use ApexCharts a lot and want your price charts to look like the others on your dashboards, generate them with a single action call — dynamic Y-axis, color-coded price levels, and multiple chart modes included. get_dashboard_yaml builds the whole dashboard with them, too (chart_card: apexcharts).

48-hour price chart colored by price level, with best price periods highlighted

📖 Chart examples & setup → | Actions reference →

❓ Help & Support

🤝 Contributing

Contributions are welcome! See the Contributing Guidelines and Developer Documentation to get started.

🤖 Development Note

This integration is developed with extensive AI assistance (GitHub Copilot, Claude, and other AI tools). While AI enables rapid development, it's possible that some edge cases haven't been discovered yet. If you encounter any issues, please open an issue — we'll fix them (with AI help, of course! 😊).

Quality is ensured through automated linting (Ruff), static type checking (Pyright), and real-world testing.

📄 License

This project is licensed under the MIT License — see the LICENSE file for details.