priceanalyzer

PriceAnalyzer - Smart Energy Management for Home Assistant

An intelligent Home Assistant integration that optimizes your energy consumption based on Nordpool electricity prices. Automatically control thermostats and hot water heaters to minimize costs while maintaining comfort.

Originally based on the excellent nordpool custom component.

PriceAnalyzer Screenshot

What does it do?

PriceAnalyzer analyzes hourly (or 15-minute) electricity prices from Nordpool and provides smart sensors that help you:

Support the Project

If you find this useful:


Features

🌡️ Climate Control Sensor (PriceAnalyzerSensor)

Provides intelligent temperature correction recommendations (±1°C) for your thermostats based on current and upcoming electricity prices.

How it works:

Sensor attributes include:

💧 Hot Water Heater Sensor (VVBSensor)

Calculates optimal water heater temperatures based on electricity prices to ensure you always have hot water while minimizing costs.

Default temperature strategy:

You can customize all these temperatures in the integration settings to match your hot water heater capacity, insulation, and household usage patterns.

Binary mode: Can also be configured as simple ON/OFF if you don’t have temperature control.

💰 Price Sensor (PriceSensor)

Displays the current electricity price with your configured additional costs (grid fees, taxes, etc.) applied.


Installation

  1. Open HACS in your Home Assistant
  2. Click the three dots (⋮) in the top right corner
  3. Select Custom repositories
  4. Add this repository URL: https://github.com/erlendsellie/priceanalyzer/
  5. Select Integration as the category
  6. Click Add
  7. Search for “PriceAnalyzer” and click Download
  8. Restart Home Assistant
  9. Go to SettingsDevices & ServicesAdd Integration → Search for “PriceAnalyzer”

Manual Installation

  1. Copy the custom_components/priceanalyzer folder to your Home Assistant config/custom_components/ directory
  2. Restart Home Assistant
  3. Go to SettingsDevices & ServicesAdd Integration → Search for “PriceAnalyzer”

Configuration

Basic Setup

When adding the integration through the UI, you’ll configure:

Step 1: Basic Settings

Step 2: Price Settings

Step 3: Advanced Settings

Step 4: Hot Water Temperature Settings Configure target temperatures for different price scenarios:

For binary control: Use values like 1.0 (ON) and 0.0 (OFF) instead of temperatures.

Multiple Setups

You can create multiple PriceAnalyzer integrations for the same region with different configurations. This is useful for:

Each setup is identified by its friendly name and creates its own set of sensors.

Reconfiguring

To change settings after initial setup:

  1. Go to SettingsDevices & Services
  2. Find your PriceAnalyzer integration
  3. Click Configure
  4. Make your changes in the multi-step menu

Usage

Automating Climate Control

Use PriceAnalyzer to automatically adjust your thermostat based on electricity prices:

Step 1: Create an Input Number helper to store your base temperature

Step 2: Import the Climate Control Blueprint

How it works:

Automating Hot Water Heater

Use PriceAnalyzer to optimize hot water heating costs:

Import the Hot Water Blueprint: Import Hot Water Blueprint

Advanced Usage

Using cheapest hours attributes in automations:

# Example: Run dishwasher during cheapest hours
automation:
  - trigger:
      - platform: template
        value_template: >
          
    action:
      - service: switch.turn_on
        target:
          entity_id: switch.dishwasher

Custom templates with additional costs: The additional costs template receives current_price as a variable:

# Add fixed grid fee + 25% tax


# Time-based additional costs

    {# Night tariff #}


Troubleshooting

Enable Debug Logging

If you’re experiencing issues, enable debug logging to see detailed information:

Via UI (Recommended):

  1. Go to SettingsSystemLogs
  2. Click Configure for custom_components.priceanalyzer
  3. Set level to Debug

Via configuration.yaml:

logger:
  default: info
  logs:
    custom_components.priceanalyzer: debug
    nordpool: debug  # For API communication issues

Getting Help


Credits

Originally based on the excellent nordpool custom component.

License

MIT License - See LICENSE file for details