Appearance
Connection Resilience
Trading automation requires constant, reliable connectivity. TTMT maintains connections to two external systems simultaneously: Telegram (for receiving signals) and your broker (for trade execution). Either connection can drop at any time due to network issues, server maintenance, credential expiration, or broker downtime.
TTMT handles this automatically wherever it can. Connections are monitored and refreshed, and in the usual case a dropped connection is reconnected without manual intervention. State is reconciled after every reconnection. Stale data is detected and flagged. The exception is a login your broker will not confirm or has refused: there TTMT slows its retries down or stops, and tells you so, rather than promising a reconnection it cannot guarantee. See Connection States.
How You Connect to Your Broker
TTMT reaches your MetaTrader account through a provider — the plumbing that carries orders and live prices between TTMT and the broker. TTMT picks it when you connect the account. Which provider you are on determines a few behaviors, so it is worth knowing yours.
| Provider | Picked when you first connect | Notes |
|---|---|---|
| TTMT Direct | MT5 accounts on brokers TTMT supports, when a TTMT Direct connection is available | The login status cards below appear only here. |
| MetaAPI Cloud | MT4 accounts, MT5 accounts on brokers TTMT does not support yet, and any MT5 account when no TTMT Direct connection is available | The standard path for these accounts. |
The trailing stop works the same on both providers. See Position Protection for how it works, and Connection Providers for how to tell which provider an account uses.
One Streaming Connection Per Account
TTMT keeps exactly one live streaming connection per MetaTrader account — a single shared feed that carries every position update, order fill, price tick, and deal event. This is deliberate: MetaAPI permits only one streaming connection per account, and a second parallel connection would fight the first, causing rate-limit storms and dropped updates. TTMT never opens a competing connection; every part of the system reads from the one shared feed.
For you, this means the connection either exists and is healthy or it is being re-established — there is no "half-connected" state where two feeds disagree. The health word on the account button in the dashboard header reflects that single feed's state directly.
Connection States
Rather than a fixed schedule of refreshes, think of your connection in terms of the states you can actually see in the dashboard:
A short interruption is not treated as a failure. The dashboard holds what it last knew for a few seconds before it says anything is wrong, so a browser pausing a background tab — or a brief network blip — passes without an alarm. Past that window it tells you it is reconnecting to your account, and shows when it last had fresh data rather than blanking the figures.
That grace applies only to the dashboard's own data feed. A problem your broker actually reports is shown immediately, with no delay.
The two login states appear on TTMT Direct accounts only.
Two of these states are about the login itself, and both are shown beside Reconnecting and Failed on TTMT Direct accounts:
| State | What it means | What TTMT does |
|---|---|---|
| Login not confirmed | Your broker closed the connection right after TTMT sent your login, three times in a row, or accepted the login and then did not keep a session. It does not mean your password is wrong. | Keeps trying, slowly. See the retry schedule. |
| Broker refused login | Your broker gave a definitive answer that is not about your password: the account is closed or expired, it is on a different server, or it needs a one-time code. | Stops trying. You fix the cause, then use Try now or Remove account. |
A third card, Login status unavailable, is not a login state. It means TTMT cannot currently read whether the broker accepted the login. Step-by-step guidance for all three is on Connection Issues.
TTMT refreshes long-lived connections and their secure credentials on its own before they can go stale — you never manage tokens or restart anything. An idle connection is re-established on demand the next time it is needed. What you see in the dashboard is the current state of the one shared feed, not the machinery behind it.
One connection, always reused
Because there is a single shared streaming connection per account, TTMT reuses it rather than opening new ones. This prevents the conflicting operations, duplicate event handlers, and rate-limit churn that multiple parallel connections to the same account would cause.
Live Connection Manager
The live connection manager handles the real-time data feed from your broker -- the stream of position updates, order fills, price changes, and deal events that TTMT relies on for live monitoring.
Defending Against Stale Position Data
One of the most subtle connection issues is ghost positions: stale position data that does not reflect reality on the broker. These appear during resynchronization events and can cause TTMT to believe positions exist when they have already been closed.
How ghost positions happen:
- The broker connection initiates a resync (periodically or after reconnection).
- During resync, the local position data may temporarily contain outdated information.
- If TTMT reads this data during the resync window, it sees positions that no longer exist.
TTMT's defense (3-layer sync guards):
| Guard | When It Runs | What It Does |
|---|---|---|
| Periodic check guard | Every position sync cycle | Validates positions against broker state before acting on them |
| Price update guard | When new price data arrives | Checks position validity when price data arrives |
| Order completion guard | When an order completes | Verifies position existence after order events |
Authoritative Broadcast
After each full sync completes, TTMT performs a clean-state refresh: it replaces its in-memory position state entirely with the freshly synced state. This purges any ghost positions left over from the resync transition.
Health Check System
TTMT monitors health at three independent levels. A failure at any level triggers appropriate responses, from logging to connection refresh to trading pause.
3-Level Health Assessment
| Level | What It Checks | Failure Impact |
|---|---|---|
| Service | Is the TTMT background service running and responsive? | Complete outage -- no signals processed, no trades managed |
| Broker Connection | Is the broker connection active and receiving live prices? | Cannot execute trades or monitor positions |
| Broker | Is the MetaTrader account responsive? | Cannot place orders; existing positions still monitored |
Service Level
The service health check verifies that the TTMT background service is alive, accepting requests, and running its monitoring work. This is the most basic health check and catches crashes, out-of-memory conditions, and startup failures.
Broker Connection Level
The broker connection health check verifies that:
- The connection is established
- Live prices are arriving -- the load-bearing signal; if quotes go stale for about 60 seconds, the connection is treated as unhealthy
- The last synchronization succeeded
- The connection age is within limits
Any one of these failing means TTMT treats the connection as unhealthy and won't trust it -- being merely "connected" isn't enough. If the broker connection is degraded, TTMT attempts automatic reconnection before flagging the issue.
Broker Level
The broker health check goes one level deeper -- it verifies that the MetaTrader account itself is responsive. The broker connection might be healthy, but the broker's server could be down for maintenance. This check catches that scenario.
TIP
The header shows one health word per account, beside the account name: OK when the connection is healthy, Closed when the market is closed, Stalled or Reconnecting when the feed is degraded, and Offline (or a Login word) when the connection is down or your broker refuses the login. The full list is on Emergency Controls.
The Reconnect Button
If your broker has been silent for about five minutes, a banner reading "Your trading connection looks down" appears with a Reconnect button. This is user-in-the-loop: you click it, and TTMT re-establishes the broker connection -- nothing redeploys or restarts on its own. Recovery is usually a matter of seconds. The five-minute prompt threshold is separate from the roughly 60-second live-price staleness window above.
Full step-by-step guidance for the Reconnect button lives on Connection Issues.
Position Sync
Even with reliable connections, state can drift between TTMT's internal records and the broker's reality. Positions can be closed manually, by a trailing stop, or by the broker itself (margin call, end-of-day). The position sync system detects and resolves these discrepancies.
How It Works
TTMT periodically compares its own records against your broker's actual positions to detect opens, closes, and modifications. Positions that have not been updated recently are flagged for investigation.
What Position Sync Catches
| Discrepancy | Detection | Resolution |
|---|---|---|
| Position closed by broker (not by TTMT) | Position in TTMT's records but not on broker | Mark as closed, reconcile P&L |
| Position opened manually | Position on broker but not in TTMT's records | Ignore (TTMT only manages its own trades) |
| Position modified externally | SL/TP values differ between TTMT and broker | Update TTMT's records to match broker |
| Stale position data | Position not updated recently | Flag for investigation, trigger re-query |
Background Safety Check for P&L Recovery
When a position closes outside of TTMT's awareness (e.g., the trailing stop fires during a brief disconnection), a background safety check ensures the trade record is properly finalized.
TTMT periodically queries the broker's trade history to find the deal that closed the position, extracts the actual P&L, and updates TTMT's trade record. If the information is not immediately available, TTMT retries automatically with increasing wait times. This ensures your performance statistics are always accurate, even when closures happen outside TTMT's direct control.
Automatic Recovery From Disconnections
When a connection drops, TTMT follows a structured recovery sequence. In the usual case no manual intervention is required.
Recovery Sequence
Reconnection Strategy
TTMT retries automatically with increasing wait times between attempts, starting quickly and gradually slowing down. Brief reconnect blips and short cooldowns are normal and handled silently -- they are not surfaced as errors. Most disconnections resolve within the first few attempts. Only a sustained failure, after retries have been exhausted, prompts you to act (via the Reconnect button described above).
When the Broker Will Not Confirm a Login
TTMT Direct accounts only
This schedule applies to accounts on the TTMT Direct provider.
A login is different from a dropped link. Every login attempt reaches your broker, and a broker that sees the same account logging in over and over may limit or lock it. So when your broker closes the connection without answering the login, TTMT does not keep retrying at full speed. The retries are bounded: a wait of about 5 minutes, then about 30 minutes, and from then on about every two hours while the market is open. After a closed market, TTMT makes another attempt within two hours of the market opening.
This schedule is a promise that attempts are made, not that they succeed. Whether the account comes back depends on your broker. The dashboard shows Login not confirmed for as long as this lasts, and Try now on that card makes one login attempt right away without restarting anything.
When the broker gives a definitive refusal instead, there is no schedule at all: TTMT stops, shows Broker refused login, and waits for you.
When TTMT Stops Connecting an Account
Some accounts cannot connect until something changes on your side. For those, TTMT stops connecting the account on its own, instead of retrying it forever. It stops only on clear evidence, never on a timeout alone:
- TTMT Direct: your broker refused the login for a reason that will not change by itself — a wrong password, an invalid account, a wrong or old server, or a one-time code that is required.
- Cloud accounts: the provider reports that the account is no longer deployed.
While the account is stopped:
- TTMT makes no automatic connection attempt for it.
- A new trade from a signal is not placed on that account, and the signal shows Account not connected. Nothing is placed and no exposure is taken. The signal is not sent again later.
- When you close a trade, move it to breakeven, or use the kill switch, TTMT still tries to connect for that action. Protective checks do the same.
The account comes back when the cause goes away:
- TTMT Direct: update the password, or reconnect the account. If your broker refused the login and the card shows Try now, it makes one connection attempt right away and lifts the stop for 10 minutes.
- Cloud accounts: redeploy the account. TTMT also checks the account with the provider every 30 minutes and resumes when it is deployed again.
If you are not sure what changed, check the account's login details on the Accounts page, or contact support.
What Happens to Existing Positions During Disconnection
The stop-loss and take-profit levels already placed on your positions live on the broker, so they keep protecting you while TTMT is briefly disconnected:
- Stop-loss and take-profit orders remain active on the broker.
- Breakeven stop losses that were already applied remain in place.
- TTMT moves the stop. While your TTMT service is restarting or cannot reach your broker, the stop stays where it is. After a restart, trailing waits 15 minutes, then continues, normally within 1 more minute.
The thing lost during a disconnection is live management — new signal processing, breakeven moves, and redistribution all resume once TTMT reconnects and resyncs.
Trailing and a disconnection
The trailing stop works the same on MetaAPI Cloud and on TTMT Direct. TTMT moves the stop. While your TTMT service is restarting or cannot reach your broker, the stop stays where it is. After a restart, trailing waits 15 minutes, then continues, normally within 1 more minute. See Position Protection for the full behavior.
A closed market is not a disconnection
If a signal arrives while the broker's market is closed, TTMT does not queue it for later — the signal is skipped immediately and no order is placed. Market-closed is a neutral, expected state, not a lost connection. Only genuine disconnections are recovered from; a closed market is simply declined. See Fast Market Conditions.
Frontend Synchronization State
The dashboard displays real-time position data that comes from the live connection. When synchronization is delayed or interrupted, the frontend detects this and alerts you.
Synchronization State
The frontend tracks whether the position data displayed is current. If the data may be stale:
- A staleness warning banner ("Synchronizing with broker...") appears prominently in the Live View, with a Refresh button if it lasts longer than 30 seconds.
- The header health word may change to match.
- Position data is still displayed but marked as potentially outdated.
This prevents you from making decisions based on stale data. When synchronization resumes, the banner clears automatically and the display updates to reflect current state.
Order Fill Recovery
When a limit order fills during a disconnection, TTMT needs to discover this after reconnecting. The system uses a 3-layer defense to ensure no fills are missed.
| Layer | Method | When It Runs |
|---|---|---|
| 1. Live reconnect | Broker resync delivers missed events | Immediately on reconnection |
| 2. Direct query fallback | Direct query to broker's deal/order history | If live resync misses events |
| 3. Admin alert | Notification that manual review is needed | If both automated methods fail |
In practice, Layer 1 catches virtually all missed fills. Layer 2 provides a safety net for edge cases. Layer 3 exists for truly exceptional circumstances.
Summary
| System | What It Protects Against |
|---|---|
| Single shared connection | Rate-limit churn from parallel connections; conflicting feeds |
| Automatic refresh | Stale connections, credential expiration, connection leaks |
| Stale-Position Defense | Stale position data during broker resync |
| 3-Level Health Check | Service, connection, and broker failures |
| Position Sync | State drift between TTMT and broker |
| P&L Recovery | Positions closed outside TTMT's awareness |
| Automatic Reconnection | Network interruptions and server restarts |
| Frontend Sync State | Decisions based on stale data |
| Order Fill Recovery | Limit order fills missed during disconnection |
INFO
All connection resilience systems are automatic. You do not need to configure anything, and in the usual case you take no manual action when connection issues occur: TTMT retries, resyncs, and resumes on its own. Where your broker will not confirm or accept a login, TTMT keeps making attempts on a slower schedule or stops, and the dashboard tells you which. The health word in the header keeps you informed of the current state.
Related pages
- Safety & Reliability Overview -- The five layers of defense
- Execution Safety -- Automatic safety pauses and error handling during operations
- Connection Issues -- The Reconnect button and connection troubleshooting
- Position Protection -- How open positions are managed
- Connection Providers -- Which provider each account uses, and how they differ
- Fast Market Conditions -- Why a closed market is skipped, not queued
- Emergency Controls -- Manual intervention when automatic recovery is insufficient

