Skip to main content
Gary
Rank 1
Rank 1
March 9, 2017
Solved

Can we get access to the OVO energy online account API to download our smart meter usage data?

  • March 9, 2017
  • 227 replies
  • 36559 views

Hi Ovo,

I wondered whether the API that powers your live and historical usage page in the account menu is something you could look into opening up a bit so we can freely access our raw data and also perhaps it may stimulate some interesting community projects?

For instance (more sport related), Strava and Fitbit.

Best answer by g-de

Updated on 14/08/25 by Abby_OVO

 

Tim_OVO: “We love seeing the innovative ways our customers are using tech to help monitor and manage their energy usage. It’s inspiring us to think about ways to do energy differently. We know some customers have been using some of the application programming interface (APIs) behind our public facing services. While we’re OK with that, we do need to make you aware of a couple of things.

 

These APIs are designed to be used by OVO teams only, and aren't public facing. There are some downsides to using APIs that aren't for the public, and we wanted to let you know what these are. Behind the scenes, OVO uses APIs to share and update information between systems that power your bills and your online account. This is done in partnership with Kaluza, the tech company that’s part of the OVO family. They’ve built the billing platform designed to put our customers in the driving seat of their energy usage. 

 

These internal APIs are intended for use by Kaluza and its clients, who are energy retailers like OVO, rather than customers. Because of this, there’s no support for them being used anywhere else, which means they may be discontinued with no notice when we update our products and services. 

 

OVO Energy and Kaluza need to be able to monitor these APIs, and may block access if there's any problems in the future.

 

We know some customers may have put time and effort into developing solutions that use these API. So, now that you know the risks, we want to hear from you on how you’re using the APIs and the problems you’re solving with your DIY approach. 

 

Is there anything you’d like to see from OVO to help you monitor and manage your energy better? Leave a comment below to tell us.”

 

can you help me understand if the links above allow users to access raw data as if from an API?

I can certainly give it a go.

 

Firstly, big thanks to Timmo and other contributors for developing the library. All thanks go to them and links to buy them a coffee for their effort can be found on PyPi or GitHub:

https://pypi.org/project/ovoenergy/
https://github.com/timmo001/ovoenergy

 

I assume the way the library was developed this was to reverse engineer the My OVO website. That is, browse the website as normal and and monitor the traffic to see what OVO URLs and APIs it uses. Assuming this is the case, one of these URLs (get account IDs) already seems to be different but the library is still working for the moment. The APIs being used are not officially supported outside of the website, so first, a warning that any changes to the My OVO website may break the library.

 

For anyone using Python, you should be able to include the ovoenergy library and look at https://github.com/timmo001/ovoenergy/blob/master/ovoenergy/cli.py for how to use it.

 

For replicating this in other languages, the process seems to be as follows:

  1. Login by sending a POST request to https://my.ovoenergy.com/api/v2/auth/login with the following JSON in the body:
    {
    "username": "...",
    "password": "...",
    "rememberMe": true
    }

    From the response, save the cookies to use in all future requests.

  2. Next, send a GET request to https://smartpaym.ovoenergy.com/api/customer-and-account-ids . Be sure to save the items in the “accountIds” property (usually only one item).
  3. Finally, make a GET request to https://smartpaym.ovoenergy.com/api/energy-usage/daily/{accountId}?date={yyyy-MM} where {accountId} is the value from the previous request and {yyyy-MM} is the month in the format 2020-08.

You can also get monthly or half-hourly usage using the following URLs similar to step 3:

As mentioned above, if this is wanted for Home Assistant, the integration was added in version 0.114 (https://www.home-assistant.io/integrations/ovo_energy/).


Unfortunately the data only goes up to the end of the previous day as OVO no longer provide real-time data:

 

227 replies

Newcomer
July 3, 2025

hah, just check again and all the data is there for 1 July.

Firedog
Super User
Super User
July 3, 2025

Has the API stopped working? Haven’t been able to get data for the last couple of days. I am Gas only.
 

I wasn’t able to retrieve Hh data for 1 July, neither via the API nor the website, until a few moments ago (09:15 BST on 03 July). Meter index readings for 2 July turned up at about the same time. It looks like there has been a delay in collecting data from meters via DCC since the start of the new quarter, but the API can only return data that has already been retrieved. 

I find it less stressful to collect my Hh data from n3rgy.com, but I still have to wait until 10:00 BST before n3rgy will get them for me.     

Noel | I have no official status; I'm just a volunteer who comes here to help other customers. My gear: Aclara SGM 1416-B Electricity-only E7 meter; Chameleon IHD3-PPMID-AAA | It may look as if I know what I’m talking about, but don’t let that fool you. |
MikeWilliams
Newcomer
Newcomer
September 22, 2025

Hi All,

Just a quick heads up OVO have changed their API.

My program will not work until I have had time to fix it.

 

Sorry about that folks, but when we use an undocumented API which is probably designed to be internal to OVO we are always at the mercy of when they decide to change their API.

 

Thanks ​@HexhamUser for notifying me.

 

Regards

Mike Williams

Firedog
Super User
Super User
October 3, 2025

OVO changes the authorization method for the Smart PAYM API 

  

People may have noticed that utilities like the ones described in this thread aren’t working these days. It looks like there was a fundamental change in the way that authorization works for the API. This sort of stuff sadly goes right over my head, but apparently it’s no longer enough to have the browser cache an access token; it actually has to be sent with each request. Developers out there will hopefully know how to deal with this, so over to ​@MikeWilliams, ​@Tron Burgundy, ​@nickcmaynard, ​@knight, ​@TerryE , ​@g-de and anyone else I’ve omitted, just in case they can be bothered to address this insofar as it affects their various code.

 

Noel | I have no official status; I'm just a volunteer who comes here to help other customers. My gear: Aclara SGM 1416-B Electricity-only E7 meter; Chameleon IHD3-PPMID-AAA | It may look as if I know what I’m talking about, but don’t let that fool you. |
Tron Burgundy
Rank 4
Rank 4
October 3, 2025

@Firedog I just tested it now and yup, Axios error in the console log.

I won’t be able to fix it either as I changed to Fuse on the 30th of September because they had me at 41p a day standing charge for electricity and every other thing cheaper than the fixed deals Ovo offered.  £150 cheaper a year, no direct debit “estimates” and no power move nonsense.

If I find a way of fixing it I’d have a go but I don’t know if I’ll be able to test it.

Newcomer
October 3, 2025

@Firedog, sorry but I am Octopus Agile these days, so I am no longer maintaining my OVO API.

Firedog
Super User
Super User
October 3, 2025

​If I find a way of fixing it I’d have a go but I don’t know if I’ll be able to test it.
  

Thanks so much for reacting 🙇‍♂️

I’ll happily act as your proxy if you could manage testing at arm’s length.

 

 

Noel | I have no official status; I'm just a volunteer who comes here to help other customers. My gear: Aclara SGM 1416-B Electricity-only E7 meter; Chameleon IHD3-PPMID-AAA | It may look as if I know what I’m talking about, but don’t let that fool you. |
MikeWilliams
Newcomer
Newcomer
October 3, 2025

I have had a quick look and it looks like they have changed to using OAuth for logging in.

I need to do some research to find out how to integrate with it.

I will post back when I have been able to fix my app.

Newcomer
October 4, 2025

I’ve done a bit of investigation. I can’t remember what it was like before so can’t say how it has changed, but the summary points are:

  • The auth doesn’t look to be OAuth, but is a combination of a request to login which sets a cookie, then “refresh” requests which use the cookie to get an auth token.
  • The refresh requests issue a token which is valid for 60 seconds. There doesn’t seem to be any replay prevention, so you can keep sending this request. I haven’t tested if it keeps working forever or stops after a period. If it does expire, there is probably a better way to “refresh”.
  • The auth token provided by the refresh endpoint is then used as a Bearer token in the authorization header.
  • There are some RPC style API requests, but most now seem to be using GraphQL. In theory this allows more control over querying, but I didn’t look  into that and just copied the queries the website was using.
  • The GraphQL queries seem to run at different at 2 different domains. The auth token works for both so doesn’t seem to have much effect, but worthy of note.

I used Restfox to test the requests. The workspace export can be found here: https://www.dropbox.com/scl/fi/5jxqer5cxlpzrpa5ouv0b/ovo.restfox.json?rlkey=5ni0j5j6olyu3jvkr3dhqm1ot&st=1j7497eo&dl=0

  1. Download the desktop app for the best experience. It may work in the browser version, but will require the CORS extension, and I haven’t tested it there.
  2. In a new workspace, import the linked file above.
  3. Open the environment settings from the button in the top right, then add JSON keys for “username” and “password” with your account details. Note: Some symbols may not work correctly, in the JSON. If that’s the case, you’ll need to change your password.
  4. Run the requests. You first need to run Login, Get Token and Bootstrap IN THAT ORDER. They retrieve some information which is required for the other requests.
  5. When your token expires after 60 seconds, you’ll need to refresh it by running Get Token again. To simplify this, use the dropdown next to the “Send” button to enable “Repeat on interval”. Set it to 45s and it should keep refreshing before the previous token expires.

Edit: There is a GrapQL request type in Restfox, but I don’t have any experience with GraphQL so used a copy paste approach from browsing the website. Feel free to provide an updated version if you work it it.

MikeWilliams
Newcomer
Newcomer
October 4, 2025

That's strange as when I was first informed of the bug I used postman to send the login request and I remember seeing the tel tale signature of a JWT in the response.