Solar panels, dynamic tariffs, domestic hot water and EV charging

Hi all,

I’m the maintainer of the openHAB Spot Price Optimizer module so I’m very familiar with dynamic tariffs. But I have zero experience with solar power.

Problem statement
I’m trying to calculate if we could get a decent payback for solar panels in our house. To achieve that, we would need to be able to heat domestic hot water with solar panels and charge our electric vehicle with it.

Background info
I believe the EV charging can be solved with a charging station which can dynamically adjust the charging power. At least Fronius Wattpilot 11J seems to be able to do this and there is also an openHAB binding for it. Fronius Wattpilot - Bindings | openHAB However, this only helps when the car is at home when sun is shining but that is usually not the case during weekdays.

This leads us to the domestic hot water. The good news in our house is that we have 180 + 300 liter tanks because we have a ground source heat pump (180 liters) and a separate boiler (300 liters), which means that it really doesn’t matter when we heat the water, as long as we do that once per day. At the moment we are doing it on the cheapest period of the day but to get a decent payback for the solar panels, that would need to be done with solar power.

Our ground source heat pump takes 2 kW and takes about 45 minutes per day for heating the domestic hot water. That equals to 1.5 kWh. Our pump is a traditional on/off pump so I do not want the compressor to stop when there is a cloud in the sky, because minimizing the compressor starts is one of the strongest drivers for me to maximize the pump lifecycle.

The boiler runs at 3 kW power and it takes about 1.5 hours every day i.e. 4.5 kWh. For this device I don’t mind if the heating is done in many parts during the day or some part of it during the day and the rest during the night.

The panels would be installed east-west and our roof is 1:7 meaning 8.13 degree angle.

Questions and considerations

  1. I know that the following question depends on gazillion different parameters, but I’ll ask it anyway. The question that I’m wondering is that are there some online calculators which I could use to guestimate how often in Southern Finland for example a 6 kWp PV system would be able to produce enough power for the water boiler i.e. run at 3 kW?
  2. Same question for the ground source heat pump but the needed power is 2 kW
  3. If we would have a Fronius inverter, I believe I could read the current production status from it with this binding so that I could then toggle the ground source heat pump / boiler ON and OFF. Fronius - Bindings | openHAB . I would most probably combine this with solar forecast but those are not accurate for timing, but would give a signal how sunny the day is to begin with.
  4. It’s probably not officially supported, but does somebody know if water boilers could be made to operate with dynamic power so that a contactor would brutally cut / allow power supply one phase at a time? This would give me the possibility to heat the water at 1 kW / 2 kW / 3 kW power depending on the solar power production status. At the moment I control our boiler so that there is a contactor but it is all-or-nothing for all three phases at the moment.

Cheers,
Markus

Ping @timo12357 - if my memory serves me well you once mentioned that you have solar panels.

For your case, the boiler is clearly the easier win—3 kW with flexible timing fits solar variability well, especially with east-west panels giving a broader production curve. Hitting a steady 3 kW in Southern Finland with a 6 kWp system won’t be constant, but you’ll likely get several usable hours on decent days (spring–summer especially). The heat pump is trickier since it prefers uninterrupted runs—personally I’d keep that on tariff optimization and use solar primarily for the boiler.

Your idea of combining inverter data + forecast in openHAB makes a lot of sense. Instead of hard ON/OFF, a staged approach (like your phase control idea) would be ideal—but most standard boilers aren’t really designed for phase-by-phase switching like that long term. A better route might be a smart diverter or modulating load controller if available in your ecosystem.

Overall, prioritize self-consumption via the boiler, accept that EV charging will be opportunistic, and keep the heat pump “happy” rather than forcing it to follow solar.

Hmm, I found the EU PVGIS service which provides a nice API so that this can be less guesswork. I asked my AI buddy to write me a small script and this is what I got out:

Analysis assumptions:
Location: Espoo, Finland
Period: 2020-2023
PV: 3.0 kWp east + 3.0 kWp west
Tilt: 8 degrees
Loss: 14%
Baseload: 450 W
Boiler: 3.0 kW fixed load, 4.5 kWh/day

=== Average per year ===
PV production: 4735 kWh/year
PV surplus after baseload: 3377 kWh/year
Boiler-usable surplus: 499 kWh/year
Boiler days/year: 41.8

=== Year-by-year summary ===
days  pv_kwh  surplus_kwh  boiler_usable_kwh  boiler_days  avg_boiler_hours_on_boiler_days
year
2020   366  4691.0       3339.9              509.8           41                              3.6
2021   365  4605.7       3252.8              435.3           38                              3.4
2022   365  4842.7       3479.6              533.0           46                              3.3
2023   365  4798.9       3435.6              516.0           42                              3.5

=== Average month per year ===
boiler_days  avg_boiler_usable_kwh_per_day  avg_boiler_hours_per_day
month
1              0.0                            0.0                       0.0
2              0.0                            0.0                       0.0
3              0.0                            0.0                       0.0
4              1.0                            0.4                       0.1
5             14.0                            5.5                       1.7
6             18.2                            7.5                       2.3
7              8.2                            2.7                       0.9
8              0.2                            0.1                       0.0
9              0.0                            0.0                       0.0
10             0.0                            0.0                       0.0
11             0.0                            0.0                       0.0
12             0.0                            0.0                       0.0


Interpretation notes:

  • A boiler day means PV surplus was enough to supply at least 4.5 kWh while surplus was >= 3 kW.
  • This is stricter than merely checking total daily surplus.
  • Because PVGIS data is hourly, short cloud variation and sub-hour control behavior are not modeled.

I don’t know about Finland, but here in Portugal billing is made in 15 minute periods. My panels are rated at 1.35KW but only during summer solar production is close to that limit. Anything “heavy” at home, such as toaster or a electric kettle, creates a consumption peak that far exceeds solar production.

There are a nunber of ways to minize electricity charges. The ones that have come to mind are:

  1. Automatically switch some devices on/off (only the ones where this can be done) in order to minimize surplus solar production sent to the grid (in 15 minute periods)

  2. Consider that PV can be considered as a discount on electricity bill, so when it exceeds 300W you can consider a 10% discount in each KW for a 3KW boiler (600W=20% discount, 900W=30% discount, …)

I am not sure if you know EVCC.
It is specialized on loading EVs but currently including also heat pumps and also some heating elements.
There is also a binding for EVCC.
So you could use EVCC to separate logic and control of wall box and heating devices and also include spot prices.

Thanks, I did not know about that solution but no software or algorithm can solve the real world constraints.

My current EV wallbox for example is not capable to dynamically adjust the charging power, it can only be adjusted with physical jumper switches so I need to anyway replace the wallbox if I can calculate a better payback time than 49 years for PV which was the result of my calculations a year ago.

But the EV part of this is totally solvable, it only needs charger which is able to adjust the power dynamically and solutions for this exist, like the one that you linked and the out of the box feature that the Fronius Wattpilot seems to have.

The thing with the 3 kW boiler is that as long as it is ON/OFF, no algorithm can change the fact that when the production is less than 3 kW, some part of the consumption needs to be purchased. Which is not a problem if the time happens to be relatively cheap in spot prices. But combining the spot price optimizing with 3 kW solar power does not sound very easy unless I can figure out a way to adjust the boiler power dynamically. Unless I increase the size of the system from 6 kWp which was my oriiginal reference.

The EU PVGIS data luckily makes this significantly easier to calculate, so I will play with that data a bit more.

And controlling the heat pump of our house heating is already highly optimized with the openHAB Spot Price Optimizer which I linked in the opening post. I’m consistently 25-30% below the spot average every month, depending mostly how volatile the prices are each month. The fact that I can already optimize so well against the spot tariffs makes the payback calculation of the solar panels hard. And the fact that I can also optimize or EV and boiler to the cheapest moments of the day, together with heating makes the difference.

For example today we charged the car and domestic hot water with just 4.75 c/kWh. And that 4.75 c includes the spot price (0.5 c) + grid tariff (1.34 c) and tax (2.92 c).

Markus

Did you check out the solarforecast binding?

I’ve come to the conclusion that adding a battery would solve this problem the easy way. I haven’t yet installed a battery though, mainly because it still seems that the payback isn’t yet economically viable, at least last time I checked, which is probably way out of date. And I also have a slight concern over fire risk.

@mstormi Yeah, I’m familiar with that. I actually already use it with my Spot Price Optimizer to predict passive heating. On sunny spring days we don’t need any heating during daytime because there is so much passive heating from sun.

@jimtng I have the same vibes as you. A battery would most definitely help with this but they are still so expensive in Finland that it’s hard to calculate the payback. And I have also small concerns about the fire risk.

Anyway, I modified my PV GIS analyzer so that I could see how the situation changes if I would be able to adjust the power of the EV charging and boiler in steps. Here are the results:

Analysis assumptions:
Strategy: EV_FIRST
Location: Espoo, Finland
Period: 2020-2023
PV: 3.0 kWp east + 3.0 kWp west
PVGIS aspects: east -80, west 100
Tilt: 8 degrees
Loss: 14%
Baseload: 450 W
Boiler mode: STAGED_1KW
Boiler: staged 1/2/3 kW (max 3.0 kW), 5.0 kWh/day
EV weekday availability: from 16:30
EV weekend availability: all day
EV 3-phase allowed: True

=== Average per year ===
PV production: 4735 kWh/year
Own consumption: base load: 1358 kWh/year
Own consumption: EV: 737 kWh/year
Own consumption: boiler: 710 kWh/year
Own consumption: total: 2805 kWh/year
Export surplus: 1930 kWh/year

=== Year-by-year summary ===
pv_kwh  base_kwh  ev_kwh  boiler_kwh  own_consumption_kwh  exported_kwh  boiler_days  boiler_hours  ev_hours
year
2020  4691.6    1351.9   763.6       713.0               2828.5        1863.1          110           570       347
2021  4606.3    1353.5   709.3       677.0               2739.8        1866.5          108           543       321
2022  4843.5    1364.0   759.0       735.0               2858.0        1985.5          112           590       352
2023  4798.8    1363.1   717.8       713.0               2793.9        2004.9          113           574       324

=== Average month per year ===
base_kwh  ev_kwh  boiler_kwh  own_consumption_kwh  exported_kwh  boiler_days
month
1          22.6     0.0         0.0                 22.6           1.1          0.0
2          65.4     0.0        10.0                 75.4          30.4          0.0
3         122.0    30.8        77.5                230.3         114.7          9.8
4         158.7   111.0        95.5                365.2         249.4         15.2
5         187.5   169.1       109.5                466.1         337.9         18.5
6         199.4   163.0       114.0                476.3         458.2         21.0
7         194.4   142.3       115.8                452.4         354.9         20.0
8         165.1    89.5       100.8                355.4         228.7         16.8
9         129.8    30.4        75.2                235.4         112.0          9.2
10         77.5     1.4        11.2                 90.1          40.0          0.2
11         26.3     0.0         0.0                 26.3           2.8          0.0
12          9.4     0.0         0.0                  9.4           0.0          0.0

Interpretation notes:

Surplus means PV production minus the assumed baseload.

Boiler mode determines whether heating is fixed 3 kW or staged 1/2/3 kW.

EV uses Wattpilot-like 1 A current steps.

Weekday EV charging is only allowed from 16:30 onward.

Weekend EV charging is allowed all day.

PVGIS data is hourly, so sub-hour cloud variation is not modeled.

Consider not to compute best run times of your boiler but switching it on and off dependent on solar surplus with some threshold and hysteresis.

It’s complex to compute one single run strategy that involves dynamic tariffing AND solar forecast AND consumption forecast AND own solar surplus AND eventually a battery for different consumer types like heat pump, ev and boilers or white good devices like the washing machine.
(As you know I’m developing a commercial HEMS that does right that.)
I’m using solar forecast binding and persist past consumption data.

You can combine everything but it’s really hard to make all consumer devices fit in let alone optimize control because of their differing runtime characteristics.
If you can interrupt at any time, surplus based on off is fairly effective but combine it with on during cheapest hours from your optimizer.

Yes, this exactly. I was checking the installation guide of my boiler and it strongly suggests that it would be possible to make it work with 1 kW steps (of course to be confirmed by the manufacturer or an authorized electrician who can interpret the drawings more reliably than me).

If the boiler 1 kW steps would be possible, then I would probably do this simply so that I use whatever I can get from the PV during daytimes. I have already attached temperature sensors to my boiler so I know exactly how much warm water there is, so the simplest approach would then to automatically check in the evening if some additional heating is needed during the night to cover that part which was not covered by PV during the day.

Markus

I have a 10.2 kWh PV battery since a couple of years. Initially i have been quite enthusiastic but after some time i saw what the efficiency means. The typical system efficiency through the PV inverter (battery & inverter) is ~80%. The battery itself may have ~85% efficiency.

Especially a low discharge power over night, e.g. 350W, is disadvantageous because the inverter efficiency drops significantly for such operating point.

If EVs are charged through the PV battery, the inverter operating point is much better w.r.t. the efficiency. But the overall system efficiency is multiplied to 80% * 80% = 64% assuming that the EV battery has similar efficiency values than the PV battery.

The good thing is, that the energy is for free at a first look. But the overall efficiency is a bit of a disaster.

Okay, I managed to integrate money aspects to the PV GIS data simulation.

The grid tariff (incl. tax) is

  • 4.26 c/kWh (Apr–Oct)
  • 6.69 c/kWh (Nov–Mar)

And I calculated with these monthly spot average prices. These are monthly actual averages between 4/2023 and 3/2026 i.e. after the energy prices had normalized in Finland after the crazy 2022-2023 fall / winter.

  • 1: 11.51
  • 2: 9.85
  • 3: 5.60
  • 4: 6.24
  • 5: 3.32
  • 6: 3.68
  • 7: 3.07
  • 8: 5.58
  • 9: 5.45
  • 10: 5.31
  • 11: 6.78
  • 12: 6.28

I did not calculate yet any money that I would get from the export. But with these assumptions, and assuming that I would be able to control the boiler in 1 kW steps, I would benefit 315 € / year (plus something little for the export surplus).

Analysis assumptions:
Strategy: EV_FIRST
Location: Espoo, Finland
Period: 2020-2023
PV: 4.0 kWp east + 4.0 kWp west
PVGIS aspects: east -80, west 100
Tilt: 8 degrees
Loss: 14%
Baseload: 450 W
Boiler mode: STAGED_1KW
Boiler: staged 1/2/3 kW (max 3.0 kW), 5.0 kWh/day
EV weekday availability: from 16:30
EV weekend availability: all day
EV 3-phase allowed: True

=== Average per year ===
PV production: 6313 kWh/year
Own consumption: base load: 1420 kWh/year
Own consumption: EV: 1175 kWh/year
Own consumption: boiler: 790 kWh/year
Own consumption: total: 3384 kWh/year
Grid tariff savings: 155 €/year
Spot price savings: 160 €/year
Total savings: 315 €/year
Export surplus: 2929 kWh/year

=== Year-by-year summary ===
year  pv_kwh  base_kwh  ev_kwh  boiler_kwh  own_consumption_kwh  exported_kwh  boiler_days  boiler_hours  ev_hours  grid_savings_eur  spot_savings_eur  total_savings_eur
2020  6255.4    1412.9  1189.1       798.0               3400.0        2855.4          131           572       427             155.5             161.2              316.7
2021  6141.7    1416.9  1129.5       768.0               3314.5        2827.2          126           556       408             151.6             155.3              306.9
2022  6458.0    1422.3  1228.0       804.0               3454.3        3003.7          133           563       456             159.3             165.9              325.2
2023  6398.3    1427.0  1152.3       789.0               3368.3        3030.1          128           567       418             153.7             159.3              312.9

=== Average month per year ===
month  base_kwh  ev_kwh  boiler_kwh  own_consumption_kwh  exported_kwh  boiler_days  grid_savings_eur  spot_savings_eur  total_savings_eur
1          27.9     0.0         0.0                 27.9           3.7          0.0               1.9               3.2                5.1
2          71.3     6.2        18.0                 95.5          45.6          0.8               6.4               9.4               15.8
3         126.6    61.5        90.0                278.1         181.9         15.0              18.6              15.6               34.2
4         162.0   171.9       108.0                441.9         377.6         18.0              18.8              27.6               46.4
5         191.8   255.7       111.5                559.0         513.0         19.8              23.8              18.6               42.4
6         204.5   241.2       115.5                561.2         684.8         21.2              23.9              20.7               44.6
7         199.4   222.6       119.8                541.7         534.8         21.5              23.1              16.6               39.7
8         170.6   143.9       108.0                422.5         356.3         19.0              18.0              23.6               41.6
9         135.8    64.7        88.8                289.3         173.9         13.5              12.3              15.8               28.1
10         85.3     7.1        30.2                122.6          50.8          0.8               5.2               6.5               11.7
11         32.1     0.0         0.0                 32.1           6.7          0.0               2.1               2.2                4.3
12         12.6     0.0         0.0                 12.6           0.0          0.0               0.8               0.8                1.6

Interpretation notes:

Surplus means PV production minus the assumed baseload.

Boiler mode determines whether heating is fixed 3 kW or staged 1/2/3 kW.

EV uses Wattpilot-like 1 A current steps.

Weekday EV charging is only allowed from 16:30 onward.

Weekend EV charging is allowed all day.

PVGIS data is hourly, so sub-hour cloud variation is not modeled.

Okay, time for conclusions:

  • If I assume that I would be able to sell the export surplus with 1.5 c/kWh, it would be an additional 44 € to the annual savings. So that would be about 360 € / year.
  • If the 8 kWp system would cost 7500 € and I would have to pay another 500 € to change my current EV charger station, the total cost would be 8000 €.
  • So the payback (excluding any interests) would be 22 years.

Yes makes sense.
An often requested setup for HEMS usage is heating rods, that’s about the same like your boiler.
Most are on-off or have two inputs to signal levels 0-3.
Here’s how that looks like in my HEMS config UI (I guess you can translate the text yourself if needed).

Oh, be very careful with conclusions from calculations like those.
There’s so much that can change over time that affects these.
Export compensation won’t be static for the pv lifetime, your own consumption will vary a lot (think changes due to future battery and EV) and so will energy prices.
You can make an educated guess but not really calculate it.

Fill your roof with as much kWp as fits on there.
Look for a good price, go get it and remember to get a battery, too.

Both, additional PV capacity and a battery pay off sooner than you might think.

Integrated control of various large consumers (like heat pump and EV) together with a battery is a challenge (and albeit related a little off topic).

Overprovisioning of PV is a rather simple option if you have the roof space available.
But the better ‘long story short’ (but in detail very very complicated) answer to that problem is:
Get a HEMS that can detect and control large consumers and that can dynamically lock battery (dis)charging during times where that’s disadvantageous to overall efficiency.

PS:
Battery efficiency varies among vendors but overall summarized it keeps improving.
Check out latest ‘Stromspeicherinspektion’ if you’re German.

Yeah, trying to think about the future scenarios was basically the rationale why I started to calculate this to begin with.

The situation in Finland is at the moment that we have so much solar and wind power installed in the last couple of years that the prices are very, very low during the spring and summer. If I would assume that status quo will remain forever, it would not make any sense to invest in PV at the moment.

However, the other side is that the highest peak in Finnish consumption at the moment is 15 MW on the country level. But there are so many data centers being built and planned at the moment, that the demand will easily eat all available capacity from the grid. All data center plans of course will not realize eventually, but to give an idea about the order of magnitude, Fingrid has received preliminary inquiries worth about 50 MW for data centers alone. And then there are other industrial level plans which will consume shitloads of electricity.

Anyway, the point is that a year ago when I tried to guestimate the payback time for PV, I ended up in 49 years. Now with these new assumptions that I listed above, the time is cut by more than 50% to 22 years. And if (when) these data center and other industrial investments change the name of the game, or the acts of our Eastern neighbor (I’m not talking about the neighbors of our house) or some other unnamed geopolitical forces change the name of the game, then the payback might be much better.

Return on Investment (= payback time) is not a good indicator to help with strategic questions.
Maximum electrification is no longer a question of “if” but at best of “how exactly” now.

PV prices won’t drop so much more, so the rest (mounting, electrician, regulatory regime, geopolitics) is much more dominant in determining the overall cost hence RoI, too.

Timing is always a matter of luck, but to wait some more won’t help with any of these, I believe.
The longer you wait, the higher the risk that something’s threatening, delaying or even killing your project (like supply shortages or lack of installer capacities because with Ukraine and Iran going on now suddenly everybody changes mind and wants to get a PV and EV).

Battery prices might be a little different, they keep dropping.
You might want to get a small but modular system that you can upgrade later, but once you factor in all one-time cost (and in particular the amount of time and energy you yourself will be putting into your project!) better consider installing it in one go.

Some thoughts about my system. I have implemented PV and batteries at our house. We also have a Nibe ground source heat pump (S1255-12) and a separate Nibe hot water boiler. We also have an EV car. Before I acquired batteries I was heating the Nibe boiler (200l, 2-phase, one resistor) with surplus PV power. I used a Carlo Gavazzi proportional control SSR (RM1E48V25) which is controlled by Ouman AXL programmable controller. I have configured a PID controller in Ouman which provides 0-10VDC voltage for the SSR. OH has a PID controller and there is a link for additional hardware, though.

When I acquired batteries I don’t bother to use the PID controller any more to heat the hot water boiler. I’m using Alfen charger for my EV car. This charger has Modbus TCP but I haven’t found a good way for controlling the charging current so I charge the car during winter time using cheap hours or during summer time I use surplus PV. I sometimes charge the car from the batteries.

Batteries are not that expensive nowadays. I have 3x15.4kWh batteries from Basengreen and a 3-phase Deye 12kW hybrid inverter which you can get easily from a reseller in Europe.

So, nowadays I don’t care that much about optimizing the hot water boiler and charging of my EV car when I get enough PV power. In addition, I can run the heat pump normally so I don’t need to “overheat” the house e.g. during cheap hours at night. dk8pn discussed above the efficiencies but I’m not that worried about this because PV power is free.

I can say that I’m very happy with my PV panels and batteries.