As thebonnotgang(1) stopped updating their database, I was wondering if there are some other free sources of high-frequency data available.

I found a proper tick data api (ca. 25 day history) hosted by onvista which is however undocumented. As some one might be interested I will add a short howto:

urlscheme: http://www.onvista.de/aktien/boxes/times+sales/export.csv?assetId=[ISIN]&assetType=[AssetType]&notation=[exchangeID]&tradingDay=[TradingDay]

[TradingDay]: Can be calculated by fixing a date e.g. 26-01-2016 as 1453791600 and subtracting the number of days multiplied by 86400. You can find the current trading day here[2]. Just klick on 'Anzeigen' as soon as the page loaded.

[ISIN]: self-explanatory I guess

[AssetType]: Up to know I was only downloading stocks so I used 'Aktie'

[ExchangeID]: I'm not able to offer a full list of all exchanges however '1937897' refers to Xetra and '9385907' refers to Tradegate. You can find more by playing around with the stock exchange dropdown menu [here][3] and looking at &notation=[***] within the url.

Example Allianz 06.01.2016: http://www.onvista.de/aktien/boxes/times+sales/export.csv?assetId=DE0008404005&assetType=Aktie&notation=1937897&tradingDay=1452063600

(I am afraid this link will be broken in a few days due to the time horizon. So it should serve just as an example)

As onvista is restructuring their homepage http://www.onvista.de/index/DAX-Index-20735?beta=off I assume they will take this service down.

So did someone discover something similar?

A similar question[4] has been asked several years ago and provides more trivial/googled results.

  1. http://thebonnotgang.com/tbg/historical-data/`

  2. http://www.onvista.de/aktien/times+sales/popup/Allianz-Aktie-DE0008404005`

  3. http://www.onvista.de/aktien/times+sales/Allianz-Aktie-DE0008404005?notation=32810950&activeType=line&activeTab=J1&displayVolume=false&min=0&max=1453935599999&zoom=false&scaling=linear`

  4. https://stackoverflow.com/questions/6225902/where-can-i-find-high-resolution-financial-data/6226589#6226589`

I didn't have 'sufficient reputation to post the links in correct mode.


2 Answers 2


For what concerns Forex data which is, however financial data after all, I often use http://www.histdata.com/. Their data is delivered in .CSV format. For timeframes, I quote the website:

We can only deliver you time ordered Tick and M1 (1 minute) data. The data that we have available is organized by forex-pair/year/month.

They also provide data for some commodities and indexes.


Stock / ETF at 5-minute intervals can be downloaded from Yahoo Finance. See the code below:

from urllib import urlretrieve
import numpy as np, pandas as pd, sys
import datetime as dt, requests
import datetime, re, StringIO

symbol = sys.argv[1]

url='http://chartapi.finance.yahoo.com/instrument/1.0/%s/chartdata;type=quote;range=3d/csv' % symbol
response = requests.get(url)
response_body = response.content
content = StringIO.StringIO(response_body)

res = []
for x in content.readlines():
    if ":" in x: continue

df = pd.DataFrame(res, columns=['Timestamp','close','high','low','open','volume'])
df.Timestamp = df.Timestamp.map(lambda x: datetime.datetime.fromtimestamp(float(x)))

df.to_csv("/tmp/%s-3d.csv" % symbol,index=None)

The complete script can be found in my quant_at project at Github, see data/hft.py. There are download scripts for equities, futures, ETFs as well.

  • $\begingroup$ chartapi.finance.yahoo.com seems to have been taken down since this answer was posted. $\endgroup$ Commented Jul 25, 2017 at 2:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.