Skip to content

Repository files navigation

Home Assistant Power NI

Power NI logo

hacs_badge GitHub Activity License BuyMeCoffee

A HACS custom integration that scrapes live electricity tariff prices from powerni.co.uk and exposes them as Home Assistant sensor entities.

All prices are the Best Deal incl. VAT for each tariff section and refresh every hour.

Why scraping?

Power NI does not offer a public API or data feed for tariff prices. There is no official Home Assistant integration, no unofficial community integration, and no machine-readable endpoint — pricing is only published on their website. Web scraping is therefore the only viable mechanism to retrieve this data programmatically.

A daily automated test monitors the live page and raises a GitHub issue automatically if the website structure changes and prices can no longer be extracted.

Sensors created

Entity Description Unit
sensor.power_ni_eco_energy_unit_rate Eco Energy best deal unit rate p/kWh
sensor.power_ni_bill_pay_unit_rate Bill Pay best deal unit rate p/kWh
sensor.power_ni_keypad_unit_rate Keypad best deal unit rate p/kWh
sensor.power_ni_electric_vehicle_anytime_day_rate EV Anytime day rate p/kWh
sensor.power_ni_electric_vehicle_anytime_standing_charge EV Anytime standing charge p/day
sensor.power_ni_electric_vehicle_nightshift_night_rate EV Nightshift night rate p/kWh
sensor.power_ni_electric_vehicle_nightshift_day_rate EV Nightshift day rate p/kWh
sensor.power_ni_electric_vehicle_nightshift_standing_charge EV Nightshift standing charge p/day
sensor.power_ni_bill_pay_economy_7_day_rate Bill Pay Economy 7 day rate p/kWh
sensor.power_ni_bill_pay_economy_7_night_rate Bill Pay Economy 7 night rate p/kWh
sensor.power_ni_bill_pay_economy_7_standing_charge Bill Pay Economy 7 standing charge p/day
sensor.power_ni_keypad_economy_7_day_rate Keypad Economy 7 day rate p/kWh
sensor.power_ni_keypad_economy_7_night_rate Keypad Economy 7 night rate p/kWh
sensor.power_ni_keypad_economy_7_standing_charge Keypad Economy 7 standing charge p/day

Installation via HACS

  1. In HACS, go to Integrations → Custom repositories
  2. Add https://github.com/Cormac131/HomeAssistant-PowerNI with category Integration
  3. Install Power NI from the HACS store
  4. Restart Home Assistant
  5. Go to Settings → Devices & Services → Add Integration and search for Power NI

Manual installation

  1. Copy custom_components/power_ni/ into your HA config/custom_components/ directory
  2. Restart Home Assistant
  3. Add the integration via the UI as above

Generated by Claude Code

This repository — including the integration code, tests, CI workflow, and documentation — was entirely generated by Claude Code, Anthropic's AI coding assistant.


About

HomeAssistant Integration for Power NI Tariffs

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages