Automating TradingView Strategies for Futures & Stocks in Interactive Brokers (IB)

2 min read

1. Introduction #

This guide explains how to automate TradingView strategies with Interactive Brokers (IB). It provides step-by-step instructions to configure trade execution, including symbol selection, order handling, and risk management settings.

By integrating IB with TradingView, traders can execute strategy-based trades automatically based on predefined conditions. This setup ensures efficient trade execution while allowing for customization in exit handling, account selection, and stop loss/take profit management.

2. Available Brokers #

Steps #

  • Select Interactive Brokers (IB) from the available options.

3. Alert Configuration #

Alert Type Options #

Alert TypeDescription
INDICATORAlerts based on technical indicators (e.g., RSI, Moving Averages).
STRATEGYAlerts based on predefined trading strategies in TradingView.

We have selected STRATEGY as our preferred alert type.

4. Instrument Type #

Choose Futures from the available choices: Futures, Futures Options, Options, Stocks.

5. Enter Trading Symbol #

Specify the trading asset (e.g., NQM6, ES) in Interactive Brokers (IB). This field is required for calculations involving Stop Loss based on ticks or total loss methods.

Important Considerations: #

  • If the symbol does not exist or is incorrectly mapped: You must configure it in IB before trades can execute on that symbol.
  • Trading a different symbol from the alert: IB allows flexibility. For example:
    • If your TradingView chart uses NQ for the alert but you want to trade MNQ, enter MNQ in the IB symbol field.
  • No symbol entered: If left blank, IB defaults to the symbol from the TradingView alert.

6. Strategy Type #

Confirm Exit Handling

Determine how exits will be managed for your strategy:

Multiple Exits (e.g., TP1, TP2): #

Yes: If your strategy has multiple exit levels (e.g., TP1, TP2), IB will not prompt for additional Stop Loss (SL) or Take Profit (TP) settings.

  • Automated Exits: Exits can be fully automated within the TradingView strategy.
  • Attaching SL/TP to Entry Orders: If you opt to attach Stop Loss and Take Profit to entry orders in IB, only one TP and one SL per order are supported. Multiple exit levels (e.g., TP1, TP2) are not accommodated in this configuration.

No: If your strategy does not handle exits, you must manually configure Stop Loss (SL) and Take Profit (TP) settings in IB.

Would your strategy have multiple exits like TP1, TP2, etc.?
No

Would you like to place Stop Loss and Take Profit orders in IB with each order from your strategy?
Yes

Stop Loss / Take Profit / BreakEven Type:
(Refer to the table in the “Select TradingView Indicator” section for a detailed explanation of each option.) Click here.


7. Account Selection #

Would you like to add multiple accounts or select a specific account for trade execution?

Yes – You can configure multiple accounts or execute trades from a specific account in Interactive Brokers (IB).

A. Add an IB Subaccount Under an Existing PickMyTrade Login #

If you have multiple IB accounts linked under a single IB login, you can allocate trades to them using quantity multipliers.

  • PickMyTrade Connection Name: Choose the IB account where you want to execute trades.
  • Quantity Multiplier: Adjusts the number of contracts proportionally for each account.

Example: #

If you have two IB subaccounts:

  • IB_Account_1 (Primary) → Multiplier: 1.5 (Executes 1.5 times the default contract size)
  • IB_Account_2 (Secondary) → Multiplier: 1.0 (Executes the standard contract size)

This setup ensures proportional trade execution across multiple subaccounts.


B. Add a Separate IB Account Under Another PickMyTrade Login #

For traders managing multiple IB accounts under different PickMyTrade logins, you can link each account individually using a unique authentication token.

  • PickMyTrade Token: Enter the token associated with the IB account you want to add.
  • PickMyTrade Connection Name: Enter the exact connection name as displayed in your PickMyTrade account.
  • Quantity Multiplier: Defines how much the contract size should be adjusted for this account.

Example: #

If you have two separate IB accounts under different PickMyTrade logins:

  • IB_Account_3 (Second IB Account) → Multiplier: 2.0
  • IB_Account_4 (Primary IB Account) → Multiplier: 1.5

In this scenario, trades in the second IB account execute at 2x the default size, while the primary account follows a 1.5x multiplier, ensuring proportional exposure across both accounts.

What are your feelings

  • Happy
  • Normal
  • Sad