MT5 Expert Advisor - Multi-Timeframe Price Action Strategy (CP/BOS/Engulfing)

Tarea técnica

# Project Specification — MT5 Expert Advisor "Prince Strategy"

## Project Goal

Develop an Expert Advisor (trading robot) for MetaTrader 5 that automates a price-action trading strategy based on candlestick patterns across multiple timeframes. The robot must work on the forex.com broker.

---

## 1. Traded Instruments

The robot must trade the following 4 forex pairs:
- GBPUSD
- EURUSD
- NZDUSD
- AUDUSD

**Important note:** For backtesting, MT5 tests one pair at a time. The robot should therefore be designed to work on the symbol of the chart it is attached to (recommended approach), or reliably handle all 4 pairs if technically feasible.

---

## 2. Strategy Architecture: Multi-Timeframe (Top-Down) Approach

The strategy uses a sequence of two timeframes:

| Step | Timeframe | Role |
|------|-----------|------|
| Bias analysis | H1 (or M30) | Determine market direction |
| Confirmation & entry | M15 (or M5) | Confirm and enter the trade |

Both the bias timeframe and the confirmation timeframe must be configurable as inputs (H1/M30 for bias, M15/M5 for confirmation).

---

## 3. Determining the BIAS (on H1/M30)

The bias (bullish or bearish direction) is determined by ONE of the following 3 patterns:

### 3.1 — Continuation Pattern (CP)

A bullish CP consists of **exactly 3 candles**:
- **B1** (oldest): bullish candle
- **B2** (middle): bearish candle, very small
- **B3** (most recent): bullish candle

**Validity conditions for the bullish CP:**
1. B3 must **fully engulf the body of B2** (B3's body must exceed B2's body, not just equal it)
2. B3 must **not be significantly smaller than B1** (B3 can be equal to or larger than B1 — this is accepted)
3. The **upper wick of B2 must not exceed the high of B3**
   - The upper wick of B2 MAY exceed the high of B1 (accepted)
   - The lower wick of B2 MAY exceed the low of B1 (accepted)
   - The lower wick of B2 MAY exceed the low of B3 (accepted)
   - ONLY the upper wick of B2 exceeding the high of B3 invalidates the CP

**The bearish CP is the exact mirror** (B1 bearish, B2 bullish very small, B3 bearish engulfing B2).

**Special cases:**
- A CP can break a zone (support/resistance) OR form "in open space" (no key level). Both cases are valid.
- On the bias timeframe (H1/M30), B3 can be long without issue.

### 3.2 — Engulfing

A bullish engulfing consists of **2 candles**:
- **B1**: bearish candle (size does not matter)
- **B2**: bullish candle that **fully engulfs B1, body AND wicks included**
  - The high of B2 must exceed the high of B1
  - The low of B2 must go below the low of B1

**The bearish engulfing is the exact mirror.**

### 3.3 — Break of Structure (BOS)

The BOS is the break of a nearby support/resistance level (not a distant one).

**Bearish BOS:**
- Identify the **close of the last bearish candle** that formed the support
- The market may consolidate near this level (several candles)
- A candle that **closes below this close** = confirmed BOS

**Invalidation condition:**
- If the breakout candle has a **wick that is too large** in the opposite direction, the BOS is invalid
- Precise rule: if the wick (lower wick for a bearish BOS, upper wick for a bullish BOS) is **larger than the body** of the breakout candle, the BOS is rejected
- A wick slightly larger than the body is tolerated, but an exaggerated wick invalidates it

**Bullish BOS = exact mirror.**

**Difference between CP and BOS:**
- CP = exactly 3 candles
- BOS = several candles (consolidation) then a breakout

**"Nearby" level:** The BOS is drawn on the most recent structure closest to the current price, not on a distant level.

---

## 4. CLEAN TRAFFIC (mandatory filter)

Clean traffic is the free space between the setup and the target. If the traffic is not clean, the setup is NOT taken, even if the bias is valid.

**Definition (bearish case):**
- In the space between the setup and the target, there must be NO **closes of bearish candles** that would form a support (obstacle)
- In other words: **no bearish candle in the traffic** (a bearish candle indicates a correction = creation of an obstacle)

**Bullish case = exact mirror**: no bullish candle (close forming resistance) in the traffic.

**Observation timeframe:** clean traffic is observed on the bias timeframe (H1/M30).

**Note:** The trader does not use pip-based measurement for distance — it is visual. The developer should propose a logic (for example: number of clean candles before the first obstacle).

---

## 5. CONFIRMATION and ENTRY (on M15/M5)

Once the bias is validated on H1/M30 with clean traffic:

### 5.1 — Draw the reference line
- Draw a line on the **high of the wick of B3** of the setup (bullish case)
- Bearish case: on the **low of the wick of B3**

### 5.2 — Wait for the break of the intermediate resistance/support
- If price reaches the close of a candle (resistance in the bullish case), wait for it to break before taking the setup

### 5.3 — Drop to M15 (or M5) and look for confirmation

Confirmation is done **only via CP or BOS** (NOT via engulfing), according to 2 scenarios:

**Scenario 1:** Price breaks the reference line directly with a CP or BOS on M15.

**Scenario 2:** Price breaks the line WITHOUT showing a CP, then forms a CP or BOS **within a maximum of 2 candles after the break**.

**Important confirmation conditions:**
- The confirmation must NOT touch the obstacle. If the obstacle is touched, there is no more space → skip the trade. (Unless the M15 confirmation breaks that obstacle, then it is valid.)
- The **B3 of the confirmation CP must NOT be too long** on M15/M5 (unlike on H1/M30), because the Stop Loss would be too large.
- For BOS confirmation: the correction before the BOS must not be exaggerated, and price must not consolidate too long before breaking.

---

## 6. TRADE MANAGEMENT

| Parameter | Value |
|-----------|-------|
| **Entry** | At the close of B3 (of the confirmation) |
| **Stop Loss** | Slightly below the low of B3 (bullish case) / above the high of B3 (bearish case). Buffer configurable in pips (e.g. 3-5 pips) |
| **Take Profit** | Risk/Reward of 1:1 (TP at the same distance as SL) |

---

## 7. RISK MANAGEMENT

| Parameter | Value |
|-----------|-------|
| Risk per trade | 1% of capital |
| Simultaneous trades | Maximum 1 trade per pair (so max 4 simultaneous trades across the 4 pairs) |
| No 2 trades on the same pair at the same time | Yes |

---

## 8. PROGRESSIVE MONEY MANAGEMENT

The lot size must evolve progressively based on results ("symmetric progressive" method):
- Base lot calculated on 1% of capital
- After each **winning trade**: the lot increases by one step (e.g. +0.01)
- After each **losing trade**: the lot decreases by one step (e.g. -0.01)
- The lot never goes below the minimum base lot
- Safety: the lot must never exceed a configurable maximum risk (e.g. 5% of capital)

---

## 9. DESIRED CONFIGURABLE PARAMETERS

The developer should expose at least the following inputs:
- Bias timeframe (H1/M30) and confirmation timeframe (M15/M5)
- Risk per trade (%)
- Risk/Reward ratio
- Stop Loss buffer (pips)
- Lot increment/decrement (money management)
- Maximum risk (%)
- Pattern detection thresholds (candle size ratios for the CP, lookback bars for the BOS, etc.) to allow fine-tuning after backtesting

---

## 10. EXPECTED DELIVERABLES

1. The commented `.mq5` source file
2. The compiled `.ex5` file
3. A functional backtest on the 4 pairs showing a coherent number of trades (the trader estimates around 2-3 setups per day per pair on average)
4. Installation and usage documentation

---

## 11. NOTES FOR THE DEVELOPER

- The strategy relies on visual judgment (wick size, "clean traffic"). Some rules will need to be translated into adjustable numeric thresholds, to be fine-tuned together after the first backtests.
- The trader can provide annotated screenshots of each pattern (valid CP, fake CP, engulfing, BOS, clean traffic) to visually clarify each rule.
- Priority: the robot should take trades faithful to the described logic, with selectivity to be refined afterwards.

---

*Specification document prepared for the development of an MT5 EA based on a multi-timeframe price-action strategy.*

Han respondido

1
Desarrollador 1
Evaluación
(107)
Proyectos
175
25%
Arbitraje
23
13% / 78%
Caducado
16
9%
Trabaja
2
Desarrollador 2
Evaluación
(15)
Proyectos
19
16%
Arbitraje
5
40% / 40%
Caducado
0
Libre
3
Desarrollador 3
Evaluación
(599)
Proyectos
693
33%
Arbitraje
43
47% / 44%
Caducado
12
2%
Trabaja
4
Desarrollador 4
Evaluación
(62)
Proyectos
90
29%
Arbitraje
24
13% / 58%
Caducado
7
8%
Trabaja
5
Desarrollador 5
Evaluación
(317)
Proyectos
564
35%
Arbitraje
81
31% / 44%
Caducado
204
36%
Libre
6
Desarrollador 6
Evaluación
(33)
Proyectos
36
33%
Arbitraje
5
0% / 80%
Caducado
0
Trabaja
Ha publicado: 2 ejemplos
7
Desarrollador 7
Evaluación
(1)
Proyectos
1
0%
Arbitraje
0
Caducado
0
Trabaja
8
Desarrollador 8
Evaluación
(7)
Proyectos
13
15%
Arbitraje
2
0% / 50%
Caducado
3
23%
Trabaja
9
Desarrollador 9
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
10
Desarrollador 10
Evaluación
(545)
Proyectos
830
62%
Arbitraje
33
27% / 45%
Caducado
23
3%
Libre
Ha publicado: 1 ejemplo
11
Desarrollador 11
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
12
Desarrollador 12
Evaluación
(3)
Proyectos
1
0%
Arbitraje
5
0% / 100%
Caducado
0
Libre
13
Desarrollador 13
Evaluación
(12)
Proyectos
18
17%
Arbitraje
3
33% / 67%
Caducado
3
17%
Libre
14
Desarrollador 14
Evaluación
(1)
Proyectos
1
0%
Arbitraje
1
0% / 100%
Caducado
0
Libre
15
Desarrollador 15
Evaluación
(12)
Proyectos
16
25%
Arbitraje
1
0% / 0%
Caducado
4
25%
Trabaja
16
Desarrollador 16
Evaluación
(77)
Proyectos
87
30%
Arbitraje
9
11% / 56%
Caducado
4
5%
Trabajando
17
Desarrollador 17
Evaluación
(25)
Proyectos
31
19%
Arbitraje
5
40% / 40%
Caducado
4
13%
Trabaja
18
Desarrollador 18
Evaluación
(1)
Proyectos
1
0%
Arbitraje
0
Caducado
0
Libre
19
Desarrollador 19
Evaluación
(55)
Proyectos
92
24%
Arbitraje
8
75% / 13%
Caducado
44
48%
Libre
20
Desarrollador 20
Evaluación
(25)
Proyectos
31
13%
Arbitraje
13
0% / 77%
Caducado
9
29%
Libre
21
Desarrollador 21
Evaluación
(2669)
Proyectos
3402
68%
Arbitraje
77
48% / 14%
Caducado
342
10%
Libre
Ha publicado: 1 ejemplo
22
Desarrollador 22
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
23
Desarrollador 23
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
24
Desarrollador 24
Evaluación
(48)
Proyectos
62
56%
Arbitraje
4
75% / 25%
Caducado
1
2%
Trabaja
25
Desarrollador 25
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
26
Desarrollador 26
Evaluación
(1)
Proyectos
8
88%
Arbitraje
0
Caducado
0
Libre
27
Desarrollador 27
Evaluación
(184)
Proyectos
317
24%
Arbitraje
23
35% / 13%
Caducado
23
7%
Libre
Ha publicado: 3 ejemplos
28
Desarrollador 28
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
29
Desarrollador 29
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
30
Desarrollador 30
Evaluación
(19)
Proyectos
24
8%
Arbitraje
9
33% / 33%
Caducado
1
4%
Trabajando
31
Desarrollador 31
Evaluación
(12)
Proyectos
21
43%
Arbitraje
8
0% / 50%
Caducado
3
14%
Libre
32
Desarrollador 32
Evaluación
(2327)
Proyectos
2930
63%
Arbitraje
124
44% / 26%
Caducado
429
15%
Trabaja
33
Desarrollador 33
Evaluación
(77)
Proyectos
244
74%
Arbitraje
7
100% / 0%
Caducado
1
0%
Libre
Ha publicado: 1 artículo
Solicitudes similares
Expert Advisor (EA) Requirements – MT5 (MQL5) Project Overview Develop an automated Expert Advisor (EA) for MetaTrader 5 based on EMA crossover signals combined with strict risk management and trade management principles. The EA must be optimized for Forex pairs and indices and should operate automatically without manual intervention. Entry Conditions Buy Setup Fast EMA crosses above Slow EMA. Current candle closes
MT5 Expert Advisor Development Project Overview I am looking for an experienced MQL5 developer to build a custom MetaTrader 5 Expert Advisor based on a grid-cycle trading framework. This is not a standard grid EA . The system combines: Session-based trade initiation Multi-filter signal generation Dynamic grid management Advanced basket management State-machine-driven trade lifecycle management Dynamic take-profit
Need an MT5 EA coded in MQL5. Strategy uses internally calculated MT5 Heikin Ashi candles, EMA 9 and EMA 21 on M1 USDJPY. Fixed lot size 12.20. One trade at a time. 40-point stop loss. Exit after 3 consecutive opposite Heikin Ashi candles. I have a detailed strategy document and video examples of valid and invalid entries. Videos linked show MT5 IOS but custom EA code will be used for windows MT5
I require a custom EA and an accompanying custom indicator built in MQL5 for Meta Trader 4/5. The EA must be fully automated (Algo Trading); Telegram-Signal-Linked and named 'AMK Fx'
MC Trader's 30+ USD
If Buy: it must Buy when a conformation is done Bye the candle that would be a bullish engolfing candle or after liqudity swip or when sellers has stepped down the market and the market regains energy and trand upwards, it's stop loss must be below the Buy position and it's take profit must be at the top of all candles
Read signal and enter trade and close trade at good profits and open trade again. Either bullish or bearish signals at 0.1 on XAUUSD. Maximum trade a day should be 4-5 times with good opens and close signals. Looking foward to a long cooperation and also a honest and genuine person
Hello, I'm looking for an expert who can help me acquire a secure, easy-to-use bot with Turkish language support for automated buying and selling in Forex, commodities, and cryptocurrencies, and who can also teach me how to set it up and use it
I need a simple bot for opening range. Simple Entry / Exit rules, to be able to customize the timeframe, time zone (entry candle) and other normal settings like size, etc
I need a new strategy with and edge for BTCUSD, optionally build an simple expert advisor for backtesting demonstration , i can build it myself if necessary, i only look for an effective strategy with an edge. Thanks
Title Professional AI Automation Trading Bot for Forex & Crypto Solution Language Python (preferred) or MQL5 depending on integration requirements. Categories Expert Advisor (EA) for MetaTrader 5 Automated trading strategies AI/ML-based signal generation Risk management automation Required Skills Strong knowledge of MQL5/Python Experience with MetaTrader API integration Machine learning model deployment

Información sobre el proyecto

Presupuesto
30 - 200 USD
Plazo límite de ejecución
a 10 día(s)

Cliente

Encargos realizados1
Número de arbitrajes0