Key Takeaways
• TradingView alerts fire once per condition; they don’t natively support multi-leg exits from a single message.
• PickMyTrade’s documented workaround uses anadvance_tp_slarray inside the alert JSON to split one position into up to three exit blocks.
• Quantity per target must be hardcoded at alert-generation time;strategy.position_sizeis not pulled dynamically.
• The workaround is documented under PickMyTrade’s Tradovate integration guide, using{{strategy.order.action}}to keep direction dynamic.
• Each exit block can carry its own stop-loss, trailing stop, and breakeven settings independently.Table of Contents
- Why Can’t TradingView Fire Multiple Take-Profits From One Alert?
- What Is PickMyTrade’s Multiple TP/SL Workaround?
- How Do You Build a 3-Target Exit Alert Step by Step?
- What Breaks If You Get the Setup Wrong?
- Multiple TP/SL vs. Splitting Across Separate Alerts
- Frequently Asked Questions
- Does TradingView support multiple take-profit levels natively?
- How many take-profit targets can PickMyTrade’s workaround handle?
- Does this workaround apply to every broker PickMyTrade supports?
- What happens if my strategy resizes positions after I set this up?
- Sources
Why Can’t TradingView Fire Multiple Take-Profits From One Alert?
TradingView alerts trigger on a condition and send one message. In Pine Script, strategy.exit() can define multiple exit orders inside your strategy logic, but the alert that fires when one of those orders executes only reports on that single fill, not a coordinated set of three. TradingView’s own documentation on strategy alerts describes placeholders like {{strategy.order.action}} and {{strategy.order.contracts}} that report what already happened, not instructions for the broker to open three separate legs. For genuine multi-leg automation, TradingView points developers toward webhooks and third-party execution engines rather than a built-in feature.
That gap is exactly what pushes traders toward workarounds. If you want TP1 at 10 points, TP2 at 15, and TP3 at 20, with position size split across all three, you need a system on the receiving end of the webhook that can parse a richer payload than “buy” or “sell.”
Citation capsule: TradingView’s strategy alert placeholders (
{{strategy.order.action}},{{strategy.order.contracts}}) report executed order details but don’t generate multiple exit legs from one alert. TradingView explicitly recommends webhooks and external tools for advanced order routing. Source: TradingView Strategy Alerts documentation.
What Is PickMyTrade’s Multiple TP/SL Workaround?
PickMyTrade documents this exact scenario under its Tradovate integration guide, titled “Adding Multiple Take Profits & Stop Losses Using PickMyTrade (Strategy Workaround).” The mechanism is an advance_tp_sl array embedded in the alert JSON. Instead of sending one quantity and one exit target, you define multiple objects inside that array, each with its own quantity, dollar_tp or percentage_tp, and dollar_sl or percentage_sl. PickMyTrade reads the whole array from a single webhook alert and manages each leg as an independent exit.
The documentation’s own example splits 5 contracts into three blocks: 2 contracts at a 10-point TP, 2 contracts at a 15-point TP, and 1 contract at a 20-point TP, each carrying a 10-point stop-loss. That’s the core idea — one alert, one JSON payload, three separately-managed exits.
Each block in the array also supports trail, trail_stop, breakeven, and breakeven_offset fields, so you can, for example, move the second target to breakeven once the first target fills, without a second alert firing.
Citation capsule: PickMyTrade’s
advance_tp_slarray lets one alert JSON define multiple exit blocks, each with independent quantity, TP, SL, trailing stop, and breakeven settings. The documented example splits 5 contracts into 2/2/1 across three price targets. Source: PickMyTrade Multiple TP/SL Strategy Workaround docs.
How Do You Build a 3-Target Exit Alert Step by Step?
The setup happens inside PickMyTrade’s Generate Alert tool, then gets pasted into your TradingView strategy’s alert message box.
- Open Generate Alert and set Alert Type to Indicator, Order Type to Market, and enter your total quantity and symbol.
- Toggle “Enable Stop Loss / Take Profit” to Yes, then turn on the Multiple TP/SL option.
- Split your total quantity across exit blocks. Assign a contract count, TP distance, and SL distance to each target.
- Copy the generated JSON template. PickMyTrade builds the full
advance_tp_slarray for you based on what you entered. - Swap the static direction for a dynamic one. Replace
"data": "buy"with"data": "{{strategy.order.action}}"so the same alert fires correctly on both long and short signals. - Paste the JSON into TradingView’s alert message box, point it at your PickMyTrade webhook URL, and save the alert on your strategy.
Here’s the example configuration from the documentation, laid out as a table:
| Target | Quantity | Take-Profit | Stop-Loss |
|---|---|---|---|
| TP1 | 2 contracts | 10 points | 10 points |
| TP2 | 2 contracts | 15 points | 10 points |
| TP3 | 1 contract | 20 points | 10 points |
That’s 5 total contracts split across three exits, all from one webhook alert firing once.
Citation capsule: The setup runs through PickMyTrade’s Generate Alert tool: enable Multiple TP/SL, assign quantity and TP/SL distance per target, then replace the static
"buy"value with{{strategy.order.action}}before pasting the JSON into TradingView’s alert box. Source: PickMyTrade docs.
What Breaks If You Get the Setup Wrong?
The documentation is blunt about one point: you cannot pull quantity from strategy.position_size. Every quantity value inside advance_tp_sl has to be hardcoded when you generate the alert. PickMyTrade will always execute the quantity written into the JSON, regardless of what your Pine Script strategy calculates for position size.
[UNIQUE INSIGHT] This is the single most common failure point traders hit with this workaround: a strategy that dynamically sizes positions based on account equity or volatility will silently mismatch the fixed contract counts in the alert, and the exits fill on the wrong size without throwing an error.
That means if you resize your account, change your risk-per-trade percentage, or switch instruments with different contract specs, you have to manually regenerate the alert JSON. There’s no automatic sync between your strategy’s position-sizing logic and the exit blocks. It’s also worth noting the workaround is documented specifically under the Tradovate integration path, so confirm the same JSON structure applies to your broker before assuming universal support across every PickMyTrade-connected platform.
Citation capsule: PickMyTrade’s documentation explicitly warns that quantity cannot be pulled from
strategy.position_size; every quantity in theadvance_tp_slarray must be hardcoded at alert-generation time, independent of your Pine Script’s calculated position size. Source: PickMyTrade Multiple TP/SL docs.
Multiple TP/SL vs. Splitting Across Separate Alerts
Some traders try a different route: firing three separate TradingView alerts, each for a fraction of the position, each pointed at the same webhook with its own hardcoded quantity and exit. It works, but it triples your alert count, your webhook calls, and your chances of one leg misfiring or getting rate-limited during a fast market. The single-alert advance_tp_sl array avoids that by keeping the whole exit plan in one payload, sent once, parsed once.
Scaling out itself isn’t a new idea. Traders have split exits across multiple price levels for decades to lock in partial gains while letting a runner ride, typically closing 50% at a first target and trailing the rest, or splitting three ways at fixed R-multiples. What’s changed is that TradingView’s alert system was never designed with that structure in mind, so the execution layer (PickMyTrade, in this case) has to carry the logic that Pine Script alerts alone can’t express.
[PERSONAL EXPERIENCE] Testing this on a demo account before going live matters more than usual here, because a hardcoded quantity mismatch won’t throw a visible error — it just executes at the wrong size, and you may not notice until you’re reconciling fills at the end of the day. That’s worth budgeting an extra ten minutes for before you flip an alert live.
Citation capsule: Scaling out — exiting a position in portions at multiple price levels rather than all at once — is a long-standing risk-management technique traders use to lock in partial gains while letting the remainder run. Source: Scaling In and Out of Trades guide.
Frequently Asked Questions
Does TradingView support multiple take-profit levels natively?
No. A single alert or strategy.exit() call reports on one order fill at a time. TradingView’s own alert documentation focuses on reporting executed order data, not coordinating multiple simultaneous exit legs, and directs traders to webhooks for advanced order routing.
How many take-profit targets can PickMyTrade’s workaround handle?
The documented example uses three targets (TP1, TP2, TP3) inside the advance_tp_sl array, each with independent quantity, TP, and SL values.
Does this workaround apply to every broker PickMyTrade supports?
The documented example is published under PickMyTrade’s Tradovate integration guide. Confirm with PickMyTrade support or your broker’s specific doc page before assuming identical JSON support elsewhere.
What happens if my strategy resizes positions after I set this up?
Nothing updates automatically. Because quantities are hardcoded, you need to regenerate and republish the alert JSON any time your position sizing, risk percentage, or instrument changes.
Sources
- TradingView Strategy Alerts documentation
- TradingView Pine Script Alerts concepts
- PickMyTrade Multiple TP/SL Strategy Workaround docs
- Scaling In and Out of Trades: A Complete Strategy Guide
