Component | Version |
v3.21.0 | |
v1.0.4 | |
v3.44.0 | |
v3.47.1 |
Last updated: Thursday, 15th May 2025
PineConnector EA
This guide provides a comprehensive overview of the PineConnector Expert Advisor (EA) settings available in your MetaTrader terminal. Understanding these settings will help you tailor the EA's behavior to your specific trading strategies and preferences.
License ID
Input your unique License ID found in the PineConnector Licensing Dashboard. This is required to connect the EA to the PineConnector server.
- It is typically a long numerical value, usually starting with a
6
or7
(e.g.,60123456789
).
Syntax Parameter Interpretation Settings
These settings define how the EA interprets specific parameters received in alert messages from TradingView.
Target Type (for sl=
and tp=
)
Determines how stop-loss (sl=
) and take-profit (tp=
) values from your alert messages are computed and applied.
- Pips (Default):
- Targets are set in pips away from the entry price (for new orders) or current market price (for modifications via
newsltp...
commands). - Example: If EURUSD is at 1.0567, a
buy
alert withsl=12
will place the SL at 1.0555. - Non-FX Instruments (e.g., NAS100/US100): The pip value might differ. For instance,
sl=10
might mean 1 point or 10 points. Always send a test trade to confirm computation for specific symbols. You may need to adjust values (e.g., multiply by a factor of 10). - Price:
- Targets are set at the exact price level specified.
- Example:
sl=1.12345
means the SL will be placed precisely at 1.12345. - Caution: This option is generally not recommended due to potential discrepancies in price quotes between TradingView and your broker, especially for target prices very close to the current market price. This can lead to order rejection errors (e.g., invalid stops).
- Percentage:
- Targets are set as a percentage away from the entry price.
- Example: If BTCUSD is at $20,000, a
buy
alert withsl=1
will mean the SL is placed 1% away, at $19,800.
Volume Type (for risk=
)
Determines how the order volume (lot size) is computed based on the risk=
parameter in your alert messages.
- Lots (Default):
- The
risk=
value directly specifies the lot size. - Example:
risk=1
means 1 standard lot will be opened. - Dollar Amount:
- The
risk=
value specifies the approximate amount of account currency you are willing to lose if the trade hits its stop-loss. The EA calculates the lot size based on this amount and the specifiedsl=
. - Example: On an EURUSD trade with a 15-pip SL, if your account currency is USD and you send
risk=10
, hitting the SL would result in an approximate loss of $10. - An
sl=
value in the alert or EA settings is required for this calculation. - Percentage of Balance, Lots:
- The lot size is calculated as a percentage of your account balance.
sl=
is not required for this calculation. - Example: With
risk=1
on a $10,000 account, a 1 lot position will be opened. (0.1 lot for $1000 account, 10 lots for $100,000 account). - Percentage of Balance, Margin:
- The
risk=
value determines the margin to be used for the position as a percentage of your account balance. - Example: If you set
risk=1
on a $1000 account, the EA attempts to open a position where the margin used is approximately 1% of the balance ($10). - Percentage of Balance, Loss:
- The
risk=
value specifies the percentage of your account balance you are willing to lose if the trade hits its stop-loss. The EA calculates the lot size. - Example:
risk=1
on a $1000 balance translates to risking a $10 loss if the SL is hit. - An
sl=
value in the alert or EA settings is required. - Percentage of Equity, Loss:
- Similar to "Percentage of Balance, Loss," but the calculation is based on account equity instead of balance.
- Example:
risk=1
on a $1000 equity translates to risking a $10 loss if the SL is hit. - An
sl=
value in the alert or EA settings is required.
Pending Order Entry Type (for pending=
)
Determines how the entry price for pending orders (e.g., buylimit
, sellstop
) is computed based on the pending=
parameter in your alert messages.
pending=
:- Positive Values Only: Values for
pending=
should always be positive. The EA intelligently determines whether to add or subtract this value from the current market price based on the pending order type (e.g., abuylimit
will be placed below market, abuystop
above). - Target Computation: Your
sl=
andtp=
targets for pending orders are still based on your selected Target Type. However, their placement will be calculated relative to the pending order's entry price, not the market price at the time the alert is received.
- Pips from Current Market Price (Default):
- The entry price is set a specified number of pips away from the current market price when the alert is processed.
- Example: With EURUSD at 1.2468, a
buylimit
alert withpending=8
will set the pending order entry price at 1.2460. - Specified Price from TradingView Alert:
- The
pending=
value directly sets the entry price. - Example:
pending=1.2460
will set the pending order entry precisely at 1.2460. - Caution: This option is generally not recommended due to potential price discrepancies between TradingView and your broker, and issues with entry prices too close to the market price (which can lead to rejections).
- Percentage from Current Market Price:
- The entry price is set as a percentage away from the current market price.
- Example: With BTCUSD at $20,000, a
buylimit
alert withpending=1
(meaning 1%) will set the pending order entry price at $19,800.
Account Filter Type (for accfilter=
)
Determines which account metric is checked when using the accfilter=
parameter in your alert messages to conditionally process signals.
- Balance:
- The signal is processed only if your account balance meets the
accfilter=
value. - Example: With
accfilter=1000
, the signal is processed if account balance > $1000. - Equity:
- The signal is processed only if your account equity meets the
accfilter=
value. - Example: With
accfilter=1000
, the signal is processed if account equity > $1000. - Free Margin:
- The signal is processed only if your free margin meets the
accfilter=
value. - Example: With
accfilter=1000
, the signal is processed if free margin > $1000. - Margin Percentage:
- The signal is processed only if your margin level (percentage) meets the
accfilter=
value. - Example: With
accfilter=200
, the signal is processed if margin percentage > 200%. - Note: If there are no open trades, your margin percentage will typically be displayed as 0 or a very high number by the broker, so the signal would likely be processed if the filter is a positive value like 200%.
Signal vs. EA Input Prioritization
This group of settings controls whether the EA uses SL, TP, and Risk values from your incoming alert messages or values set directly within the EA's input parameters.
- The Target Type selected in the EA will determine how EA-inputted SL and TP values are calculated (Pips, Price, or Percentage).
- The Volume Type selected in the EA will determine how an EA-inputted Risk value is calculated
Parameter Source Setting ("Setting")
Determines which values (from the alert signal or from EA inputs) are used for SL, TP, and Risk when processing incoming signals.
- Signal Parameters Only:
- The EA ignores any SL, TP, and Risk values set in its own input fields.
- All trades are processed strictly according to the
sl=
,tp=
, andrisk=
parameters found in your alert message. - EA Parameters Only:
- The EA uses the SL, TP, and Risk values specified directly in its input fields.
- Any
sl=
,tp=
, andrisk=
parameters in the incoming alert message are ignored. - This is useful if you want to adjust SL/TP/Risk settings globally for a strategy without modifying all individual alerts on TradingView.
- SL/TP from EA, Risk from Signal:
- The EA uses the SL and TP values from its input fields.
- The
risk=
value from the alert message is used for volume calculation. - SL/TP from Signal, Risk from EA:
- The EA uses the
sl=
andtp=
values from the alert message. - The Risk value from its input field is used for volume calculation.
- Scenario 1: Using "Signal Parameters Only"
- EA Inputs: SL=10, TP=15, Risk=1
- Signal Parameters:
sl=20, tp=25, risk=2
- Result: EA processes with SL=20, TP=25, Risk=2.
- Scenario 2: Using "EA Parameters Only"
- EA Inputs: SL=10, TP=15, Risk=1
- Signal 1 Parameters:
sl=20, tp=25, risk=2
- Signal 2 Parameters:
risk= (no sl= or tp= specified, e.g., LicenseID,buy,EURUSD,risk=1)
- Result: Both signals processed with EA Inputs: SL=10, TP=15, Risk=1.
- Scenario 3: Using "SL/TP from EA, Risk from Signal"
- EA Inputs: SL=10, TP=20, Risk=1
- Signal Parameters:
sl=15, tp=25, risk=2
- Result: EA processes with SL=10 (from EA), TP=20 (from EA), Risk=2 (from Signal).
- Scenario 4: Using "SL/TP from Signal, Risk from EA"
- EA Inputs: SL=10, TP=20, Risk=1
- Signal Parameters:
sl=15, tp=25, risk=2
- Result: EA processes with SL=15 (from Signal), TP=25 (from Signal), Risk=1 (from EA).
EA Input Values for Stop Loss, Take Profit, Risk
These are the fields in the EA's input settings where you can define default SL, TP, and Risk values. These are used if the "Parameter Source Setting" (Section C.1) is configured to use "EA Parameters Only" or one of the mixed modes.
- Values: You can typically input any positive numerical value, including decimals (e.g.,
0.1
,10
,10.123
). The interpretation depends on the selected Target Type and Volume Type.
General Trading Behavior Settings
Pyramiding
Determines how the EA handles multiple incoming signals for the same symbol and direction.
This EA option typically only recognizes positions opened by this PineConnector EA instance unless Magic Restriction off is turned off in the EA.
- On: All incoming trade signals will attempt to open new positions without restrictions based on existing positions for that symbol/direction.
- On — If Symbol & Direction in Profit: An incoming signal (e.g., buy EURUSD) will only open a new position if the sum of all existing open positions for that symbol and direction (e.g., all buy EURUSD trades) is currently in profit (>$0).
- Off — Either 1 Buy OR 1 Sell: Only one position (buy or sell) is allowed per symbol.
- Example: If you have 1 buy EURUSD position, a new sell EURUSD signal will not open. A new buy EURUSD signal will also not open.
- Off — Only 1 Buy AND 1 Sell: Allows one buy and one sell position simultaneously for the same symbol (hedging).
- Example: If you have 1 buy EURUSD position, an incoming sell EURUSD signal will open. However, another buy EURUSD signal will not open if one already exists.
Close on Reverse
Determines how the EA handles signals that are opposite to existing open positions for the same symbol.
This EA option typically only recognizes positions opened by this PineConnector EA instance unless Magic Restriction off is turned off in the EA.
- On — Hedging: When an opposite signal is received (e.g., a
sell
signal whenbuy
positions are open for that symbol), existing open positions for that symbol in the original direction are closed, and then the new position in the opposite direction is opened. - Example: If you have 3 buy EURUSD positions open, an incoming
sell EURUSD
signal will result in the 3 buy EURUSD positions closing, followed by the new sell EURUSD position opening. - On — Netting: When an opposite signal is received, existing open positions for that symbol in the original direction are closed, but the new position in the opposite direction is not opened.
- Example: If you have 3 buy EURUSD positions open, an incoming
sell EURUSD
signal will result in the 3 buy EURUSD positions closing, and no new sell position will be opened from that signal. - Off: Incoming signals do not affect existing open positions based on their direction (standard behavior, new trades open independently subject to pyramiding rules).
Shadow Targets
This feature aims to hide your actual intended stop-loss and take-profit levels from the broker by placing the visible SL/TP orders much further away, while the EA monitors the true intended levels internally.
Note: This feature might not be compatible with some other EA features that rely on actual SL/TP orders being at specific levels.
- On:
- Shadow Targets will be used. The actual SL and TP orders sent to the broker will be placed arbitrarily (e.g., 100 pips) further than your intended SL and TP prices defined by your signal or EA inputs. The EA then monitors the true intended SL/TP levels and closes the position when these are hit.
- Requires
sl=
andtp=
parameters to be present in the signal or EA settings for the intended levels. - Off (Default): Standard SL and TP orders are used.
- ATR Trailing
- Pip Trailing
- Breakeven
Partial Close Percentage
Determines the percentage of an open position's volume to close when using the closelongpct
or closeshortpct
syntax commands.
This EA option typically only recognizes positions opened by this PineConnector EA instance unless Magic Restriction off is turned off in the EA.
- 25%: Closes 25% of the position's volume (allowing for up to 4 partial closes).
- 34%: Closes approximately 33.33% of the position's volume (allowing for up to 3 partial closes).
- 50%: Closes 50% of the position's volume (allowing for up to 2 partial closes).
- The EA will automatically round the volume to the nearest permissible lot size by your broker.
- With Magic Restriction On (default): EA will only partially close positions opened by this PineConnector EA.
- With Magic Restriction Off: EA will attempt to partially close positions on that symbol regardless of how they were opened (manually or by other EAs), subject to FIFO or other broker rules if multiple positions exist.
Maximum Open Positions
Defines the maximum total number of positions that can be open simultaneously across all symbols by this EA instance.
This EA option typically only recognizes positions opened by this PineConnector EA instance unless Magic Restriction off is turned off in the EA.
- 0 (Default): EA does not limit the total number of open positions.
- Any positive number (e.g., 5, 10): EA limits the total number of open positions to this specified number. The EA may print its current position count on the chart.
- With Magic Restriction On: Only positions opened by this PineConnector EA are counted towards the limit.
- With Magic Restriction Off: The EA attempts to count all positions on the account (manual, other EAs) towards the limit. However, this filter only stops new signals from this EA from opening trades if the limit is breached; it doesn't prevent manual trades or other EAs from exceeding the limit.
Maximum Open Positions per Symbol
Defines the maximum number of positions that can be open simultaneously for any single symbol by this EA instance.
This EA option typically only recognizes positions opened by this PineConnector EA instance unless Magic Restriction off is turned off in the EA.
- 0 (Default): EA does not limit the number of open positions per symbol.
- Any positive number (e.g., 1, 3): EA limits the number of open positions for any single symbol to this specified number.
On-Chart Dashboard Settings
Settings related to the information display panel on your MetaTrader chart.
Profit Computation (for Dashboard)
Determines how profit is calculated and displayed on the on-chart dashboard.
- With Commission, Taxes and Swap (Default): Profit shown is comprehensive, taking into account commissions, taxes, and swap fees.
- Without Commission, Taxes and Swap: Profit shown on your dashboard does not include these costs.
- Note: The profit displayed will likely be higher with this option. It's primarily useful for comparing trading performance across different brokers with varying cost structures.
Font Size (for Dashboard)
Determines the size of the text and values displayed on the on-chart dashboard.
- Any integer representing a reasonable font size.
- Examples:
10
,15
, or20
.
Show Dashboard
Determines whether the information dashboard is displayed on the chart.
- On (Default)
- Off
Account Protection Settings
These settings help manage risk by defining profit targets and loss limits for your trading account, with automated actions when these levels are reached. This will be useful when managing your capital, and for those who trade for prop firms such as FTMO.
Daily Profit Target & Action
Daily Profit: Sets a daily take-profit target for your account. The daily calculation period resets at midnight GMT+0.
0
→ Off (Default): Daily profit target feature is inactive.0 < x ≤ 1
→ Percentage (%) of Day's Starting Balance:- Example:
0.01
(for 1%). If the starting balance for the day is $10,000, the target equity is $10,100. Once equity ≥ $10,100, "Action (Daily)" triggers. More than 1
→ Dollar ($) Amount:- Example:
100
. If the starting balance is $10,000, the target equity is $10,100. Once equity has increased by $100 or more, "Action (Daily)" triggers.
Check your MetaTrader "Experts" Log for the calculated day's profit target value.
Action (Daily): Determines what happens when your Daily Profit target or Daily Loss limit (see below) is reached.
- Halt EA: The PineConnector EA will be halted for the remainder of the current trading day (GMT+0) and will automatically restart on the new day.
- Close All Positions: All open market positions and pending orders managed by the EA are closed. The EA continues to operate.
- Close All Positions and Halt EA: All positions/orders are closed, and the EA halts for the day, restarting on the new day.
Daily Loss Limit & Action
Daily Loss: Sets a daily stop-loss limit for your account. Resets midnight GMT+0.
Options:
0
→ Off (Default): Daily loss limit feature is inactive.0 < x ≤ 1
→ Percentage (%) of Day's Starting Balance:- Example:
0.01
(for 1%). If the starting balance is $10,000, the loss limit equity is $9,900. Once equity ≤ $9,900, "Action (Daily)" triggers. More than 1
→ Dollar ($) Amount:- Example:
100
. If the starting balance is $10,000, the loss limit equity is $9,900. Once equity has decreased by $100 or more, "Action (Daily)" triggers.
Action (Daily): Determines what happens when your Daily Profit target or Daily Loss limit (see below) is reached.
- Halt EA: The PineConnector EA will be halted for the remainder of the current trading day (GMT+0) and will automatically restart on the new day.
- Close All Positions: All open market positions and pending orders managed by the EA are closed. The EA continues to operate.
- Close All Positions and Halt EA: All positions/orders are closed, and the EA halts for the day, restarting on the new day.
Cumulative Profit Target & Action
Cumulative profit is the total net profit your account has earned (excluding deposits and credits) since the EA started tracking or since the last reset of this cumulative value.
Cumulative Profit: Sets an overall take-profit target for your account based on cumulative gains.
0
→ Off (Default): Cumulative profit target feature is inactive.0 < x ≤ 1
→ Percentage (%) of Initial/Tracked Balance:- Example:
0.25
(for 25%). Once total account equity reaches a 25% gain over the initial tracked balance, "Action (Cumulative)" triggers. More than 1
→ Dollar ($) Amount:- Example:
1000
. Once total account equity has increased by $1000 (cumulative profit), "Action (Cumulative)" triggers.
Action (Cumulative): Determines what happens when your Cumulative Profit target or Cumulative Loss limit (see below) is reached.
- Halt EA (Day): The PineConnector EA halts for the current trading day (GMT+0) and restarts automatically on a new day.
- Halt EA (Persistent): The PineConnector EA halts indefinitely until manually resumed.
- Click the “Resume PineConnector EA” button on the chart (if available).
- Re-attach the PineConnector EA to the chart.
- Send an
eaon
signal:LicenseID,eaon,eaon
. - Close All Positions: All open market positions and pending orders are closed. The EA continues to operate unless another limit also triggers a halt.
- Close All Positions and Halt EA (Day): All positions/orders are closed, and the EA halts for the day.
- Close All Positions and Halt EA (Persistent): All positions/orders are closed, and the EA halts indefinitely until manually resumed.
Cumulative Loss Limit & Action
Cumulative loss is the total net loss your account has incurred (excluding deposits and credits) since inception or last reset.
Cumulative Loss: Sets an overall stop-loss limit for your account based on cumulative losses.
0
→ Off (Default): Cumulative loss limit feature is inactive.0 < x ≤ 1
→ Percentage (%) of Initial/Tracked Balance:- Example:
0.10
(for 10%). Once total account equity drops by 10% from the initial tracked balance, "Action (Cumulative)" triggers. More than 1
→ Dollar ($) Amount:- Example:
1000
. Once total account equity has decreased by $1000 (cumulative loss), "Action (Cumulative)" triggers.
Action (Cumulative): Determines what happens when your Cumulative Profit target or Cumulative Loss limit (see below) is reached.
- Halt EA (Day): The PineConnector EA halts for the current trading day (GMT+0) and restarts automatically on a new day.
- Halt EA (Persistent): The PineConnector EA halts indefinitely until manually resumed.
- Click the “Resume PineConnector EA” button on the chart (if available).
- Re-attach the PineConnector EA to the chart.
- Send an
eaon
signal:LicenseID,eaon,eaon
. - Close All Positions: All open market positions and pending orders are closed. The EA continues to operate unless another limit also triggers a halt.
- Close All Positions and Halt EA (Day): All positions/orders are closed, and the EA halts for the day.
- Close All Positions and Halt EA (Persistent): All positions/orders are closed, and the EA halts indefinitely until manually resumed.
Advanced & Miscellaneous Settings
EA Magic Number
Assigns a unique "magic number" to trades opened by this instance of the PineConnector EA.
- Example:
- Strategy 1 EA: Uses License ID 1 with magic number
76
. It opens and manages only trades with magic number 76. - Strategy 2 EA: Uses License ID 2 with magic number
77
. It opens and manages only trades with magic number 77. - Both EAs operate independently on the same account.
You may watch this YouTube video for the setup and showcase.
- 76 (default)
- 77
- 78
- 79
- 80
Magic Restriction
Determines whether the EA's actions (closing, modifying, counting positions) apply only to trades opened by itself (matching its Magic Number) or to all trades on the account for a given symbol.
- On (Default): The EA will only affect/recognize positions and orders that it opened (i.e., those matching its own EA Magic Number).
- Example: An incoming
closelong
command will only close long positions opened by this specific PineConnector EA instance. - Off: The EA will attempt to affect/recognize all positions and orders for the relevant symbol, regardless of whether they were opened by this EA, manually, or by another EA.
- Example: An incoming
closelong
command will attempt to close all long positions for that symbol on the account.
- Closing Commands: (
closelong
,closeshort
,closelongvol
, etc.) will attempt to close positions opened manually or by other EAs. - Pyramiding: Will count and use profit information from positions opened manually or by other EAs when evaluating pyramiding rules.
- Close on Reverse: Will execute its logic on positions opened manually or by other EAs.
- Max Open Positions / Max Open Positions per Symbol: Will count all relevant positions on the account towards these limits. (Note: This filter primarily stops this EA from opening new trades if the limit is breached by any combination of trades).
- SL and TP Modifications: (
newsltp...
commands) will attempt to modify SL/TP of positions opened manually or by other EAs.
Broker Set (MT5 EAs Only)
Adjusts some internal EA settings to optimize compatibility with specific broker server configurations or regional requirements. Do not change unless advised by PineConnector support or if you are experiencing specific issues related to order filling.
- Automatic (Default)
- Set A
- Set B — Unsupported Filling: (Try if experiencing issues with order execution types).
- Set C — Brazilian Brokers: (Specific adjustments for brokers in Brazil).
EA Active Hours
Allows you to define specific hours during which the PineConnector EA will process incoming signals. Outside these hours, signals are ignored.
- The time is based on your Broker's Server Time as printed on the chart.
- Start Time:
00:00
to23:59
- End Time:
00:00
to23:59
- Examples:
00:00
to23:59
(or24:00
if EA accepts it): EA always active.08:15
to12:20
: EA processes signals only from 8:15 AM to 12:20 PM broker time.22:00
to09:00
: EA processes signals from 10:00 PM broker time until 9:00 AM broker time the next day (overnight trading).
Symbol Prefix / Suffix
Allows the EA to automatically add a prefix and/or suffix to the symbol received in an alert message before attempting to trade it. This is useful if your broker uses non-standard symbol names (e.g., "EURUSD.m" or "proEURUSD").
- Prefix: Any string (e.g.,
broker.
) - Suffix: Any string (e.g.,
.mini
) - Example: If Prefix is
broker.
and Suffix is.mini
, an alert forEURUSD
will be translated by the EA tobroker.EURUSD.mini
.
DLL Logs
Enables or disables the collection of detailed logs from the EA's underlying DLL (Dynamic Link Library). These logs capture background processes and are typically only needed for debugging specific technical issues, often at the request of PineConnector support.
- Off (Default)
- On
PineConnector Analytics
Enable this to share your trading history with PineConnector. This allows you to view your trading account performance and data analytics on the PineConnector Portal.
- On (Default)
- Off
Auto Update EA
Enable or disable the EA's ability to automatically check for and download the latest EA files. The update check typically occurs when the EA initializes (e.g., when first attached to a chart or when MetaTrader starts and the EA connects with your License ID).
- Off
- On (Default)
Enable Symbols
Configure whether symbols are enabled upon attaching the PineConnector EA
- Yes - Enable all symbols
- Yes - Enable up to 50 symbols (default)
- No - Hide all enabled symbols
- No - Retain enabled symbols
On this page
- PineConnector EA
- License ID
- Syntax Parameter Interpretation Settings
- Target Type (for sl= and tp=)
- Volume Type (for risk=)
- Pending Order Entry Type (for pending=)
- Account Filter Type (for accfilter=)
- Signal vs. EA Input Prioritization
- Parameter Source Setting ("Setting")
- EA Input Values for Stop Loss, Take Profit, Risk
- General Trading Behavior Settings
- Pyramiding
- Close on Reverse
- Shadow Targets
- Partial Close Percentage
- Maximum Open Positions
- Maximum Open Positions per Symbol
- On-Chart Dashboard Settings
- Profit Computation (for Dashboard)
- Font Size (for Dashboard)
- Show Dashboard
- Account Protection Settings
- Daily Profit Target & Action
- Daily Loss Limit & Action
- Cumulative Profit Target & Action
- Cumulative Loss Limit & Action
- Advanced & Miscellaneous Settings
- EA Magic Number
- Magic Restriction
- Broker Set (MT5 EAs Only)
- EA Active Hours
- Symbol Prefix / Suffix
- DLL Logs
- PineConnector Analytics
- Auto Update EA
- Enable Symbols