Skip to main content
On this page

FX Replay Backtesting Guide: Setup, Trade Journals, and Validation

· 8 min read
Pineify Team
Pine Script and AI trading workflow research team

FX Replay lets you practice trading on historical data and review simulated trades. Its value depends on how consistently you apply your rules: replaying a chart faster does not make the result more reliable. This guide explains a reproducible forex testing workflow, with a hypothetical example rather than claimed trading results.

What FX Replay Can Help You Test​

Historical replay is useful for rules that require a person to interpret a chart. You can pause before making a decision, record it, and advance to see the outcome. A demo account instead exposes your process to incoming market data and the practical constraints of following it in real time. Both are simulations; neither establishes how an order would fill with a live broker.

FX Replay organizes testing into sessions that hold a selected date range, trades, and statistics. Its official getting-started FAQ describes creating sessions from the Dashboard. The workflow starts in FX Replay; connecting a TradingView account is not a prerequisite described in those instructions.

Set Up a Session You Can Reproduce​

  1. Write a rule sheet first. Specify the pair, chart interval, trading hours, entry trigger, stop, exit, position size, and treatment of missed trades.
  2. Choose New Session in the Dashboard. Select the symbol and date range and give the session a name that identifies the rule version.
  3. Record the environment. Note the data feed, timezone, account balance, and any cost or execution settings you can configure. Keep unsupported costs in a separate calculation.
  4. Check the chart clock. A London trading window can move relative to UTC with daylight saving time. Write down whether your rules mean London local time or a fixed UTC interval.
  5. Advance without revealing later bars. Log the decision before advancing. If you recognize a historical event, note that the period may no longer be a clean blind test.

The Session Indicator documentation distinguishes UTC and New York options. Check the selected timezone against your rule sheet instead of relying on the visual session label alone.

There is no universal best timeframe. Choose one that can represent your signal and intended holding period. A setup that depends on the order of price changes inside a minute cannot be validated from minute OHLC bars alone.

A Hypothetical London-Range Test​

The following is a test specification, not a recommended or proven strategy. It illustrates the details that must be settled before replay begins.

DecisionExample rule
MarketEUR/USD, 15-minute bars
RangeHighest high and lowest low from 08:00 up to 09:00 Europe/London time
SignalFirst completed bar closing outside that range after 09:00
EntryNext bar's available execution price; one attempt per day
ExitA 20-pip stop or 40-pip target; close any remaining position at 12:00 London time
Ambiguous barIf a bar touches both stop and target, inspect available finer data or report both possible outcomes
Missing dataExclude the affected session and record why; never silently fill the gap

The stop and target are arbitrary teaching inputs. They say nothing about whether this range has predictive value. Test them only after specifying costs, position size, and how gaps or unfilled orders are handled.

Check the Arithmetic Before Interpreting the Pattern​

Suppose an invented sample contains 40 winners of +2R and 60 losers of −1R, where R is the same initial cash risk for every trade. Before costs:

  • Gross profit is 40 × 2R = 80R; gross loss is 60 × 1R = 60R.
  • Net result is +20R across 100 trades, or +0.20R per trade.
  • Profit factor is 80 ÷ 60 = 1.33, although the win rate is only 40%.

If every round trip costs 0.10R, total costs are 10R and the net result falls to +10R. These totals do not reveal maximum drawdown: that requires the order of trades and the equity path. Do not convert an R total into an account return without applying the actual sizing and compounding rules.

Use the Journal to Audit Decisions​

Record the entry timestamp, direction, entry and exit prices, initial stop, size, costs, and outcome. Add the rule version and a screenshot taken at the decision point. Also record skipped and invalid setups so the journal does not contain only memorable trades.

Separate these two kinds of notes:

Note typeWhat it recordsHow to use it
Decision-time observationInformation visible before the tradeCan define a future trading rule
Post-trade explanationWhat became clear after the outcomeA hypothesis to test on another period

For example, discovering that losses cluster near news releases does not justify removing those trades from the original result. Keep the original run and test a predeclared news filter on later data. The platform's trades and logging guide explains its journal and trade-list controls; your audit notes should remain tied to a specific session and rule version.

Holdout Testing and Walk-Forward Testing Are Different​

A single chronological split creates a development period and one later holdout. Tune on the first and run the frozen rules once on the second. A 70/30 split is merely one possible allocation; it is not a statistical guarantee.

Walk-forward testing repeats the process across time: develop using a window, test on the following window, advance both windows, and join only the test-window results. Decide the window lengths and retuning policy before looking at those results. Reusing a failed holdout to tune new rules turns it into development data.

No trade count proves validity. Trades from the same session or market shock can be highly dependent. Review the duration covered, concentration in a few trades, changes in volatility, and sensitivity to execution costs alongside the sample size.

Platform Boundaries to Check​

Custom indicators: FX Replay's compatibility guidance says its custom indicators use FXR Script and require adapting Pine Script. A TradingView-looking chart does not establish identical calculations or automatic Pine strategy compatibility. Compare a few indicator values and signal timestamps after conversion.

Multiple pairs: Compare synchronized returns and overlapping positions if your account trades several pairs. Price-level correlation alone does not measure strategy diversification. Two USD exposures can lose together during an event even if their earlier measured correlation was modest.

Resampling: If you export trades for Monte Carlo analysis, document whether you shuffle trades or sample with replacement and how you handle dependent trades. The resulting paths are conditional scenarios, not a forecast or a bound on future losses. This guide does not assume a particular built-in simulation feature is available in your plan.

Execution: Confirm whether the replay models spreads, financing, commission, slippage, and simultaneous orders. A visually reached price does not establish a live fill. Run additional cost scenarios for anything the platform omits.

Before You Treat a Result as Evidence​

Save the rule sheet, session settings, complete trade record, and cost assumptions together. Recalculate several trades independently. Then compare the unchanged rules on later data and in forward simulation, recording disagreements between expected and observed signals. A result that depends on one unusually favorable trade or a narrow cost assumption deserves further investigation.

Do I need a TradingView account to begin an FX Replay session?

The official starting workflow is to log into FX Replay and create a session from its Dashboard. Custom indicator compatibility is a separate issue; Pine Script may require adaptation to FXR Script.

How many forex trades make a backtest reliable?

There is no fixed number. Consider dependence between trades, coverage of different periods, execution assumptions, and how many alternative rules you tested. A large count from one market episode can still provide weak evidence.

Does a high win rate mean my replay strategy is profitable?

No. Compare average win, average loss, and all trading costs. Also inspect drawdown and exposure. The hypothetical calculation above shows why win rate alone is insufficient.

Can replay replace forward testing?

Replay examines historical decisions. Forward simulation checks whether you can recognize and execute those decisions as new data arrives. Neither reproduces every aspect of live liquidity or fills.