You can also try the “Time Of Use - Flexible” app if the one stuart wrote doesn’t suit.
Enter in your rates/times and you can then see how much it would have cost you if you had been on the new TOU plan. It doesn’t handle solar feed in though, so you’d need to do that calculation separately, and you need an EmonCMS feed that includes only your Imported energy to correctly calculate costs.
I have two feeds in my EmonCMS in addition to an “ImportkWh” feed (which goes negative when I’m exporting), called “ImportOnlykWh” and “ExportOnlykWh”, which reflect the absolute value of the positive and negative values of ImportkWh respectively. I can then use the ImportOnlykWh to calculate costs based on TOU (using the app above), and then use the ExportOnlykWh value to calculate feed-in manually.
I’m still working on a new “more flexible” app that will handle solar feed in as well, but can offer no promises on when that might be finished.