How to install the TWS API Components on Mac / Unix

NOTE: If you have already agreed to the API License Agreement please start at Step 3 below.

Instructions

  1. Click directly on the button below to access the API software download page. 
  2. This will direct you to Interactive Brokers API License Agreement, please review it.
  3. Once you have clicked "I Agree", refer to the Mac / Unix section to download the API Software for your o.s.
    API Software Download List
  1. This will download twsapi_macunix.n.m.zip to your computer.
    (where n and m are the major and minor version numbers respectively)
  2. Open Terminal (Ctrl+Alt+T on most distributions)
    (On Mac press Command+Space to launch Spotlight, then type terminal and press Return)
  3. Navigate to the directory where the installer has been downloaded (normally it should be the Download folder within your home folder) and confirm the file is present.

     $  cd ~/Downloads
     $  ls

  1. Unzip the contents the installer into your home folder with the following command (if prompted, enter your password):
    $  sudo unzip twsapi_macunix.n.m.zip -d $HOME/
    Installation directions Step 3 and Step 4
  2. To access the sample and source files, navigate to the IBJts directory and confirm the subfolders samples and source are present.
    $  cd ~/IBJts
    $  ls
    Installation directions Step 5
 

 

Legacy Instructions - API Version ≤ 9.71

Note: IB only offers API Version 9.72+. In the event you already have an existing legacy version and need to install it, please refer to the directions below:

  1. locate the file twsapi_macunix.n.m.jar on your computer.
    (where n and m are the major and minor version numbers respectively.)
  2. Open Terminal (Ctrl+Alt+T on most distributions)
    (On Mac press Command+Space to launch Spotlight, then type terminal and press Return)
  3. Navigate to the directory where the .jar file has been located (normally it should be the Download folder within your home folder) and confirm it is present.
    cd ~/Downloads
    $  ls
  4. Extract the contents of the .jar file into your home folder.
    $  jar xf twsapi_macunix.n.m.jar -d $ HOME/
  5. To access the sample and source files, navigate to the IBJts directory and confirm the subfolders samples and source are present.
    $  cd ~/IBJts
    $  ls
 
 

Additional Information 

You can as well refer to KB2222 for video instructions on installing the Legacy API Components on a Mac.

 

Feedback

Please provide feedback on this information

Please note that while we read and take into consideration all feedback, we are not able to respond directly to comments or questions submitted through this forum. Should you have an inquiry or require assistance, please contact Customer Service.