Trading Evolution

Markets are never wrong - opinions often are

Download historical Forex data from Interactive Brokers

I added few more arguments to IbCmd tool for historical data download. For example to download last 10 days of Open, High, Low, Close data for EUR/USD pair use following list of parameters:

IbCmd.exe /s:EUR /t:Cash /e:IDEALPRO /f:EURUSD.csv /d:10

The tool will output EURUSD.csv file which can be opened in Excel or any other spreadsheet editor.

12/15/2015 12:00:00 AM,1.099625,1.105975,1.090475,1.093025
12/16/2015 12:00:00 AM,1.0925,1.101175,1.0888,1.091275
12/17/2015 12:00:00 AM,1.0909,1.09145,1.080275,1.0826
12/18/2015 12:00:00 AM,1.083425,1.08745,1.080525,1.0864
12/21/2015 12:00:00 AM,1.085975,1.0939,1.084825,1.09145
12/22/2015 12:00:00 AM,1.091375,1.098425,1.090225,1.09565
12/23/2015 12:00:00 AM,1.095225,1.0957,1.087025,1.091175
12/24/2015 12:00:00 AM,1.090975,1.096775,1.090425,1.096375
12/28/2015 12:00:00 AM,1.0964,1.099275,1.095625,1.09685
12/29/2015 12:00:00 AM,1.0967,1.098025,1.096625,1.097925

If you want 10 days of 5 minute bars then add /b:FiveMins


IbCmd.exe /s:EUR /t:Cash /e:IDEALPRO /f:EURUSD.csv /d:10 /b:FiveMins

Interactive Brokers Limitations

When you use this tool you need to be familiar with Interactive Brokers historical data download limitations. The following table lists the valid duration and bar size settings for historical data requests. Requesting the same historical data in a short period of time can cause pacing violations from Interactive Brokers.

More details can be found here: Historical Data Limitations