Skip to content

Automated trading

How to Measure TradingView-to-MT5 Latency Without Mixing Up Alert, Receipt and Fill

Measure TradingView-to-MT5 latency between two named events on aligned clocks. Alert-to-receipt, receipt-to-processing and alert-to-broker-fill are different intervals. A single “execution speed” number hides which interval was measured and whether a trade actually filled. Broker ping is narrower still: it measures a terminal's network connection to its broker server, not the journey from alert to order or fill.

Start with the question you need to answer. Are messages arriving late, is receiving-side processing delayed, or is the broker outcome still unresolved? Your timestamps need to distinguish those possibilities.

Alert to receipt to fill. Measure named stages. Branded topic diagram.
Measure named stages

Define the start and finish before collecting data

An alert timestamp is not automatically the time a chart condition first became true. For a strategy order-fill alert, TradingView generates the event when its broker emulator fills a simulated order. That is separate from a live MT5 fill, as TradingView explains in its alerts FAQ.

Use a record like this for each intended instruction and receiving account:

Stage What the timestamp must represent
Alert event The actual selected TradingView alert event
Receipt Arrival at the receiving service, where evidenced
Processing A defined processing event, such as processing start or completion
Broker request Submission of the trading request, where evidenced
Broker outcome Rejection, first deal or final filled volume, identified separately

Use the events your logs actually expose. These are measurement categories, not a promise that every product supplies every timestamp. Record each field's meaning and resolution. A generic “processed” label cannot be treated as both processing start and broker execution.

TradingView's webhook documentation describes delivery of the alert message to a URL. Delivery evidence does not establish a broker fill. MetaQuotes also distinguishes orders, deals and positions: one order can involve multiple deals, an order can be rejected, and an accepted pending order has not filled. Decide whether your fill endpoint means first execution or completion of the intended volume.

Know what each record can show

Each stage leaves evidence in a different place. These records answer different questions, so use them together instead of treating any one as an end-to-end stopwatch.

Measurement or record What it can tell you What it cannot establish alone
TradingView alert log Whether and when the alert triggered, and its message A completed broker trade
PineConnector signal history Receipt and recorded processing of that signal Every earlier delivery stage or a broker fill
Broker ping Terminal-to-broker connection information Total alert-to-order or alert-to-fill time
MT5 Experts and Journal EA activity, terminal requests and broker responses That the original strategy triggered as intended
Broker positions and history The account's resulting orders, deals and positions Why an earlier stage took time

Read Edge's broker ping as a snapshot

On Edge, Broker ping is the terminal-to-broker measurement stored when the terminal last connected. Check the Measured time to understand its age. A dash means the value is unavailable. It is not a continuous live measurement.

The instance's location tells you where the hosted terminal runs. It does not establish the broker server's physical location, and a country in the broker's company name is not enough to infer it. See the Edge connection reference for the current field meanings.

Moving a terminal may change its network path to the broker. It does not remove the earlier TradingView and PineConnector stages or the broker's own order handling, so hosting near a broker cannot guarantee a particular fill time, fill price or trading result.

Align clocks, not just displayed time zones

Convert timestamps to one comparison zone, such as UTC, while preserving the originals and their offsets. Include the date. For interpreting the original displays, see broker server time versus UTC and TradingView time.

Timezone conversion alone does not synchronise clocks. If the receiver's clock is ahead of the source clock, subtracting their timestamps includes that offset. Establish clock synchronisation and any known error where you control the machines; document uncertainty for clocks you cannot verify.

Resolution matters too. A log that displays whole seconds cannot substantiate a 40-millisecond interval. Preserve finer timestamps when genuinely available, but do not create precision by adding decimal places. Negative or implausible intervals should prompt a clock and event-matching check before a speed conclusion. If you cannot align the clocks or identify the stage boundaries, describe the observed records separately instead of publishing a millisecond claim.

An illustrative timeline and stage sum

Invented elapsed timestamps are 0, 180, 240, 260 and 410 milliseconds for alert, receipt, processing complete, broker request and complete fill. Intervals of 180, 60, 20 and 150 milliseconds sum to 410; receipt to fill is 230.
Illustrative timings, not a benchmark. Consecutive intervals total 410 ms; receipt to fill is 230 ms.

The following numbers are invented solely to explain the calculation. They are not observed results, a PineConnector benchmark or a speed promise. Assume the clocks behind these timestamps are aligned and each timestamp accurately identifies the stated event.

Event Illustrative UTC time
Alert event 08:00:00.000
Receiver receipt 08:00:00.180
Processing complete 08:00:00.240
Broker request submitted 08:00:00.260
Complete fill recorded 08:00:00.410

The consecutive intervals are 180 ms, 60 ms, 20 ms and 150 ms. Their sum is 410 ms, equal to the final timestamp minus the first.

These intervals cover elapsed time between observations. The first may include more than network transit; the last may include several broker-side steps. Do not rename either as a pure network measurement, or compare it directly with a broker ping figure, without additional evidence.

If only receipt and fill are visible, you can calculate receipt-to-fill, subject to clock uncertainty. You cannot infer alert-to-receipt or allocate the hidden processing stages. Mark them unknown. Add only consecutive, non-overlapping intervals; adding alert-to-fill to receipt-to-fill counts part of the journey twice.

Calculate p50 and p95 from the actual sample

Keep one row per intended instruction and account, linking the alert record, receipt, request and broker tickets where available. A timestamp match alone is weak when several similar alerts occur together. Separate repeated deliveries from separate intended trades.

For each precisely defined interval, sort the valid measured durations. State your percentile method. Under the nearest-rank method, p50 is the value at rank ceiling(0.50 × n), and p95 is at ceiling(0.95 × n), counting from one. With 100 valid observations, those are the 50th and 95th sorted durations. Their values must come from your measurements.

Report the sample size, collection period, account environment, configuration and missing outcomes. A small sample gives a fragile view of the slow tail. Pooling different brokers or configurations can also hide the condition causing delays.

Keep rejected, unfilled and unresolved instructions visible separately. An alert-to-fill percentile calculated only from completed fills describes that subset. It says nothing about how often other instructions failed to fill.

Investigate one delayed event

A slow interval identifies where to look, not necessarily the cause. A fast receipt is compatible with a rejected request. A fast fill can still have an unexpected price; slippage measurement is a separate exercise.

Start with one specific alert and the intended broker account. Record the date, time and timezone, symbol, action and message. If one License ID serves several accounts, investigate the result for each relevant recipient separately.

  1. TradingView. Locate the alert-log entry. Confirm that the actual message matches what you expected and check any webhook delivery information available. A chart marker is not sufficient evidence that an alert was sent.
  2. PineConnector. Find that signal in Portal → Bridge → Logs and inspect its processing result. The Edge tag identifies Edge processing. Read any reported latency according to the stage it describes; do not add overlapping intervals or rename a processing duration “total execution time”.
  3. MT5. Match the event in the terminal's Experts and Journal, or the corresponding tabs for an Edge instance, and read the full broker response.
  4. Broker account. Confirm the outcome in positions and history. This is where you distinguish a slow accepted request from a rejected request or an instruction that never reached the terminal.

Check the broker outcome before repeating a command. Missing confirmation leaves the outcome unknown, not failed. The first request may already have produced an order, and another instruction can create additional exposure. When an endpoint is missing, use the stage-by-stage no-trade diagnosis, the alert troubleshooting guide and the current PineConnector documentation.

Compare hosting without inventing precision

For a useful comparison, keep the broker account type, server, symbol, EA configuration and test method as consistent as practical. Use demo and observe multiple events across relevant sessions. Record both ordinary timings and unusually slow events, together with failures and missing observations, and apply the same clock and percentile rules to each environment.

Demo observations do not guarantee identical live execution. Market conditions and the broker's handling remain part of the result.

Use ping to inform the network-location question. Use matched alert, processing and broker records to understand the actual journey. Choose hosting on that evidence alongside compatibility, recovery and operating effort, rather than buying the smallest advertised latency number.

Back to PiCo Blog

Run your strategies on our managed infrastructure

Bridge routes TradingView alerts to MetaTrader. Edge hosts and runs MT5 for you.

Core Trial

Then $59/month unless you cancel.

$7for 7 days

  • 3 account connections
  • 1 hosted MT5
  • Unlimited alerts, routed by Bridge
Try Core for $7

Trusted by 66,000+ traders in 156 countries and territories · <1s typical latency

Your Edge MT5 runs in our cloud · nothing to install · built on Microsoft Azure