Hi
Does anyone know if its possible to get API access to fund performance data at Hargreaves Lansdown - want to get daily data into my spreadsheet to monitor fund performance.
Cheers
Arun
Got a credit card? use our Credit Card & Finance Calculators
Thanks to Anonymous,bruncher,niord,gvonge,Shelford, for Donating to support the site
Hargreaves Lansdown API access
-
- Lemon Quarter
- Posts: 4137
- Joined: November 4th, 2016, 9:24 am
- Has thanked: 3293 times
- Been thanked: 2871 times
Re: Hargreaves Lansdown API access
ArunC wrote:Hi
Does anyone know if its possible to get API access to fund performance data at Hargreaves Lansdown - want to get daily data into my spreadsheet to monitor fund performance.
Cheers
Arun
Not API access but you can probably scrape the data from a web page.
An alternative is HYPTUSS https://lemonfoolfinancialsoftware.weeb ... op-up.html
This does have a worksheet which scrapes fund prices from the FT
--kiloran
-
- Posts: 6
- Joined: February 18th, 2023, 2:03 pm
Re: Hargreaves Lansdown API access
Tried scraping, but the column headers change every day, so it works on the day the power query in excel was set up, but the next day the headers change so cant find the data, does anyone know a way around this, been trying for hours....
-
- Lemon Half
- Posts: 9109
- Joined: November 4th, 2016, 1:16 pm
- Has thanked: 4140 times
- Been thanked: 10061 times
Re: Hargreaves Lansdown API access
ArunC wrote:
Tried scraping, but the column headers change every day, so it works on the day the power query in excel was set up, but the next day the headers change so cant find the data, does anyone know a way around this, been trying for hours....
Sorry to be blunt, but *which* column headers...?
As far as I can tell at the moment, you're looking for a mind-reader first and foremost...
Why not provide a sample URL, and then specify just which field or fields you're looking to use, and then people might be able to engage with your query more effectively, because as things stand, I can't see how anyone can help with such a vague and confusing request...
Cheers,
Itsallaguess
Last edited by Itsallaguess on June 18th, 2023, 8:24 am, edited 1 time in total.
-
- Posts: 6
- Joined: February 18th, 2023, 2:03 pm
-
- Posts: 6
- Joined: February 18th, 2023, 2:03 pm
Re: Hargreaves Lansdown API access
The problem was this. The table on the page has a header row with dates, and a first row of data with annual return.
The dates change every day, so when the power query runs on the date it is set up the data returns fine, but the next dat, because the column headers have changes, the query cant find the data because the query if looking for headers from the previous day.
AI found this solution, replacing the power query code with the following (where the URL is the page being scraped, and Source(0) refers to the table reference on that page
let
Source = Web.Page(Web.Contents("URL")),
Data = Source{0}[Data],
Headers = Table.PromoteHeaders(Data, [PromoteAllScalars=true]),
NoHeaders = Table.Skip(Headers, 1)
in
NoHeaders
The example is on this page: https://www.hl.co.uk/funds/fund-discoun ... s-i-income table 5 (annual return)
The dates change every day, so when the power query runs on the date it is set up the data returns fine, but the next dat, because the column headers have changes, the query cant find the data because the query if looking for headers from the previous day.
AI found this solution, replacing the power query code with the following (where the URL is the page being scraped, and Source(0) refers to the table reference on that page
let
Source = Web.Page(Web.Contents("URL")),
Data = Source{0}[Data],
Headers = Table.PromoteHeaders(Data, [PromoteAllScalars=true]),
NoHeaders = Table.Skip(Headers, 1)
in
NoHeaders
The example is on this page: https://www.hl.co.uk/funds/fund-discoun ... s-i-income table 5 (annual return)
Return to “Financial Software - Discussion”
Who is online
Users browsing this forum: No registered users and 15 guests