While studying various strategies for trading the FOREX market, I came across the "London Open Breakout Strategy" — a well-known approach aimed at achieving stable, low-risk profits.1,2,3
This project implements a backtesting framework for this strategy on EUR/USD, GBP/USD, and GBP/JPY markets. It uses price action, Asian session range breakout logic, and filters based on economic news data. I have also used MACD and RSI as momentum indicators to avoid false breakouts, filtered out trades on days with major economic news, and applied the SMA to follow the market trend. However, using these momentum indicators, news filters, or trend-following logic is optional and depends on your preferences.
My investigation shows weak results when applying this strategy. (At least with the most common variations on the mentioned markets). I have also tried to make the project as flexible as possible, to easily modify for further analysis.
- Strategy Overview
- Project Goals
- How to Customize
- Required Data
- Features of the current version
- Results
- Requirements
- Quick Start
- References
The main goal of this project is to evaluate the effectiveness of the 'London Open Breakout Strategy' using a structured, transparent backtesting framework.
This project is not about proving the strategy "works" — it is about discovering when and how it works best (if at all), and building a toolset that allows others to continue that exploration.
Since interpreting the outcomes is more valuable than just generating trade signals, a detailed results analysis module has been built. You can skip to the Results section to see how the performance is evaluated.
The idea behind the "London Open Breakout Strategy" is based on the belief that during the first 1.5 hours of the London session the market has the potential to break through the daily support or resistance of the Asian session, and if the breakout happens, market will show a considerable average shift. The following table reviews the key properties of this strategy.
Strategy Overview Table
| Aspect | Details |
|---|---|
| Strategy Type | Breakout trading at London session open based on Asian session range |
| Core Concept | Trade breakout above or below Asian session high/low |
| Timeframe to Mark Range | Asian session |
| Entry Signal | Candle closes outside Asian session range at London open |
| Stop Loss Placement | Just outside opposite side of range |
| Profit Target | Generally 1.5x to 3x risk; typically 20–30 pips |
| Win Rate | Approx. 50%–55% |
| Best Pairs | GBP/USD, EUR/USD, GBP/JPY |
| Potential Advantages | Simple, objective, exploits high liquidity and volatility |
| Risks | False breakouts, news spikes, spread widening |
| Suggested Risk Management | Risk 1%–2% per trade; use confirmation to avoid false breakouts |
Like any other strategy, there are an infinite number of variations can be explored by adjusting the strategy's parameters. Some variables that I have considered in this code to allow for flexible analysis include:
- Using news days to skip trading, using RSI to confirm breakouts, using MACD to confirm breakouts
- Timeframe to mark range (some prefer a portion of the Asian session to extract the range of the market)
- Using the SMA to avoid trading against the trend, with a customizable window
- Take-Profit value (Profit range can be considered as long as 2 times of Asian market range or a fixed amount of pips)
- Stop-Loss value (Loss range can be considered as long as the Asian market range or a fixed amount)
- Time-frame for backtesting (Tested on 15 minutes and 30 minutes time-frames)
- Start and end date of the analysis
The main dataset required to run this code is the market data of EUR\USD, GBP\USD, and GBP\JPY in 15 minutes (recommended in references). However, there are functions to connect to your MetaTrader5 to fetch the historical data to use the data provided by your broker. If the analysis skips trades on major news days, you will also need an Excel file listing each currency and the analysis days, with a 1 inserted in cells that there are news. In the current repo, market data and the news data are included in data folder starting from 2024/07/12 to 2025/07/11.
- SMA, RSI and MACD integration
- News filtering
- Position tracking (SL/TP logic)
- Time-based exit logic (Positions will close at the end of the day.)
By selecting different variables for this analysis the results would differ. These results are based on a sample configuration and may vary depending on parameters selected.The current configuration is:
- Time frame is 15 minutes
- Skipping signals on news days
- Asian time range to extract the range: 00:00 to 07:00 GMT
- using SMA with a time window of 50
- Take Profit range is equal to two times of the Asian session range
- Stop loss range is equal to range of the Asian session range
- Start date is 2024/07/21
- End date is 2025/07/20
These plots show the performance of this strategy:
Key insights:
Trends in GBPJPY is stronger.
EURUSD remains relatively flat, with low volatility and minor gains.
GBPUSD shows the weakest performance, ending near breakeven or slightly negative.
The strategy performs best from August 2024 to January 2025, with a noticeable peack and mild drawdown afterward.
This result emphasizes the importance of pair selection, dynamic filters, and seasonal market conditions.
This highlights the importance of ongoing evaluation and adaptive parameter tuning.
As you can see, the confusion matrix below shows how well the strategy predicted price direction after generating trade signals.
- Total predictions: 242
- Accuracy: ~54.1%
- True Positives (Buy → Price Up): 74
- True Negatives (Sell → Price Down): 57
- False Positives (Buy → Price Down): 65
- False Negatives (Sell → Price Up): 46
The strategy correctly predicts upward moves more often than downward ones. However, a high number of false buy signals suggests further refinement is needed — particularly around breakout confirmation and market condition filters.
You can find individual confusion Matrix for each symbol (EURUSD, GBPUSD, GBPJPY) saved in the results/ folder.
This histogram shows the distribution of profit and loss per trade, based on all trades during the backtest period.
- Average PnL per trade: +0.00018 USD
- Standard deviation: 0.00429 USD
Most trades result in small gains or losses, forming a roughly normal distribution. The slightly positive mean indicates a mild statistical edge. A few outliers on the positive side suggest the presence of rare, highly profitable trades. Risk appears controlled, but refining entry conditions and reward-risk ratios may enhance returns.
You can find individual Profit and Loss histograms for each symbol (EURUSD, GBPUSD, GBPJPY) saved in the results/
folder.
This chart shows a profitable buy (long) trade generated by the London Open Breakout strategy. The entry occurred after a breakout above the Asian session high, followed by a price increase that hit the TP level.
Additional examples, (Unprofitable long trades, Profitable short (sell) trades, Unprofitable short trades) are
available in the results/ folder for further analysis and comparison.
- Python 3.9+
- MetaTrader5 (installed and configured)
- Python libraries listed in requirements.txt file
Follow these steps to set up and run the London Open Breakout strategy on your machine.
git clone https://github.com/mhzardary/london-strategy-backtest.git
cd london-strategy-backtestpython -m venv .venv.venv\Scripts\activate
source .venv/bin/activate
pip install -r requirements.txtCreate a .env file inside the config/ folder, check env.example as a template.
python main.pyResults will be saved in results folder.
To run all unit tests:
pytest test/While this project provides a solid foundation for testing the London Open Breakout Strategy, these enhancements can be considered to improve strategy:
Considering supports and resistance of higher time frames may help to avoid false signals.
Some trades trigger in the London session, however the breakout has happened during late hours of Asian session. These trades should be filtered out.
This project considers either a TP/SL equal to Asian session range or a fixed range. Using adaptive TP SL based on market conditions could enhance the profit.
I would consider tick volume as an estimation of real volume to confirm the breakouts.
Using indicators like Bollinger Bands or ATR would help to filter out some fake breakouts.
This project is licensed under the MIT License.
This software is provided for educational and research purposes only. Use it at your own risk. The author assumes no responsibility for any losses or damages resulting from the use of this software.
London Breakout Strategy – What it is & How to Trade it! (2024)
London Breakout Strategy: Rules and Backtest Performance (2025)
Keenbase Editorial Staff _. (2020). London Breakout Strategy - A Simple way of Day Trading
.png)
.png)
.png)
