TerminalBridge Trade Copier
- Utilitaires
- Version: 1.1
TerminalBridge Trade Copier
TerminalBridge Trade Copier is a local MetaTrader 5 position copier designed to synchronize trading actions between two MT5 terminals running on the same Windows computer or VPS.
One terminal operates as the MASTER and publishes position changes. The second terminal operates as the SLAVE and receives and processes these events through the shared MetaTrader Common Files folder. Both roles are included in the same EX5 file.
Main Features
- Local MT5-to-MT5 position copying
- Selectable MASTER and SLAVE roles in one EX5 file
- Copies manually opened positions
- Copies positions opened by Expert Advisors, scripts and trading panels
- Monitors MASTER positions regardless of Magic Number or comment
- OPEN position synchronization
- Stop Loss and Take Profit synchronization
- Partial close synchronization
- Full close synchronization
- Fixed 1:1 volume ratio
- Maximum volume per trade protection
- Maximum spread and price deviation controls
- Signal expiration validation
- Optional MASTER and SLAVE symbol suffix mapping
- Automatic account position mode detection
- Heartbeat connection monitoring
- Persistent position mapping
- Restart recovery and duplicate execution protection
- On-chart MASTER and SLAVE status panels
How It Works
The MASTER terminal monitors current positions and publishes position lifecycle events. The SLAVE terminal validates the publisher identity, Link ID, event sequence and configured safety settings before applying the corresponding action.
The supported position events are:
- OPEN
- SLTP_MODIFY
- PARTIAL_CLOSE
- FULL_CLOSE
Processed operations are recorded in persistent local storage. This state allows the product to restore its mappings after an EA reload or terminal restart and helps prevent the same event from being executed twice.
Source Position Policy
The MASTER role monitors all positions on the source account. Positions may be opened manually, by another Expert Advisor, by a script, by a trading panel, or through MetaTrader mobile and web terminals.
Magic Number and position comment are retained as diagnostic information but are not used to exclude source positions.
Requirements
- MetaTrader 5
- Two MT5 terminals running on the same Windows computer or VPS
- Both terminals running under the same Windows user
- Access to the same MetaTrader Common Files folder
- Automated Trading enabled on the SLAVE terminal
- The same Link ID configured on both terminals
- The MASTER account login entered in the SLAVE settings
This version uses local MetaTrader Common Files communication. It does not transmit signals over the internet and does not connect terminals located on different computers.
Account Position Mode
The account position mode is detected automatically. The product operates according to the position accounting mode reported by the connected MetaTrader 5 account.
The default AUTO setting is recommended. Explicit NETTING and HEDGING selections are available for configuration validation. If an explicit selection does not match the connected account, initialization is stopped to prevent an incorrect configuration.
Symbol Mapping
By default, the MASTER and SLAVE symbol names must be identical. Optional suffix fields can be used when brokers apply a consistent symbol suffix.
Examples:
- EURUSD maps to EURUSD
- EURUSD maps to EURUSD.a
- EURUSD.m maps to EURUSD.pro
The product performs exact suffix transformation only. It does not perform fuzzy symbol matching or alias conversion such as XAUUSD to GOLD.
Volume and Safety Controls
The current version uses a fixed 1:1 volume ratio. Copied volume is normalized according to the SLAVE symbol volume step and is limited by the Maximum Volume Per Trade setting.
Before processing a trading event, the SLAVE validates the applicable configuration and safety conditions, including:
- Trade copying enabled state
- MASTER account identity
- Link ID
- Signal expiration
- Maximum spread for OPEN operations
- Maximum price deviation
- Symbol availability and suffix mapping
- Account position mode configuration
- Persistent recovery state
Connection Monitoring
The MASTER and SLAVE panels display the local peer heartbeat state. A green connection indicator confirms that the expected peer terminal is active for the configured Link ID.
A disconnected heartbeat does not necessarily mean that the broker connection is unavailable. It means that the expected TerminalBridge peer has not been detected within the heartbeat timeout.
Recovery and Duplicate Protection
TerminalBridge stores position mappings, operation identities and processing revisions in persistent local files. After a terminal restart or EA reload, the product restores its state before allowing new trade execution.
Previously processed events are identified and are not executed again. Closed historical mappings are retained for recovery and duplicate detection while the panel reports only active mapped positions.
Input Parameters
Role
Select MASTER to publish source positions or SLAVE to receive and execute position events.
Link ID
Connection identity shared by the MASTER and SLAVE terminals. The same value must be used on both terminals.
Log Level
Select ERROR, INFO or DEBUG diagnostic output.
Account Position Mode
AUTO detects the connected account mode automatically. NETTING and HEDGING can be selected for explicit configuration validation.
Master Account Login
MASTER account number expected by the SLAVE. This setting is ignored in MASTER mode.
Volume Ratio
The current version uses a fixed 1:1 ratio.
Maximum Volume Per Trade
Maximum volume that may be opened on the SLAVE for one copied position.
Master Symbol Suffix
Optional suffix removed from the MASTER symbol before mapping.
Slave Symbol Suffix
Optional suffix added to the mapped SLAVE symbol.
Enable Trade Copying
Allows trade execution on the SLAVE when set to true. This setting is ignored in MASTER mode.
Maximum Spread
Maximum allowed spread in symbol points for an OPEN operation.
Maximum Price Deviation
Maximum broker request deviation in points.
Signal Expiration
Maximum accepted age of a received position event.
Quick Start
- Install TerminalBridge Trade Copier on two MetaTrader 5 terminals running under the same Windows user.
- Attach the product to one chart in the source terminal.
- Select MASTER as the Role.
- Choose a Link ID.
- Attach the same EX5 to one chart in the target terminal.
- Select SLAVE as the Role.
- Enter the same Link ID used by the MASTER.
- Enter the MASTER account login in the SLAVE settings.
- Leave Account Position Mode set to AUTO unless explicit configuration validation is required.
- Configure symbol suffixes only when the brokers use different consistent suffixes.
- Set Maximum Volume Per Trade and the required safety limits.
- Enable Trade Copying on the SLAVE.
- Enable Automated Trading in the SLAVE terminal.
- Confirm that both panels display a connected peer heartbeat.
- Test the configuration with a small volume before normal use.
Important Notes
- Communication is local to the same Windows computer or VPS.
- Both MT5 terminals must run under the same Windows user.
- One MASTER and one SLAVE are recommended for each Link ID.
- Use a different Link ID for every independent MASTER and SLAVE pair.
- The current volume ratio is fixed at 1:1.
- Symbol mapping supports exact names and consistent suffix transformation only.
- The SLAVE account must have sufficient free margin for copied operations.
- Execution prices may differ between accounts.
- Spread, liquidity, symbol specifications and broker settings may produce different execution results.
- Stop Loss and Take Profit levels may be rejected when they do not satisfy the SLAVE broker requirements.
- The product does not guarantee identical execution price, profit or loss between accounts.
- External modification of copied SLAVE positions may affect subsequent synchronization.
Test the complete MASTER and SLAVE configuration with a small volume before using it in your normal trading environment.
