Join waitlist
Strategies / Momentum / RSI MACD Midline Cross Long

RSI MACD Midline Cross Long

Buys when RSI(14) crosses above 50 while MACD(12,26,9) is above its signal line, or when MACD crosses above its signal with RSI at or above 50. Exits when RSI falls back below 50 or MACD crosses below its signal with a non-positive histogram.

MomentumLong onlySwingDAX 404 hours
1.22Profit factor
13,117Net profit EUR
32.67%Win rate
1,402Trades
-2,222Max drawdown
9.36Avg trade

Best run of 20. DAX 40, 4 hours, spread 3, from run pf:2026-10-12-DAX40-4h.tsv:2.

Entry rules, long

  1. MACD(12,26,9) crosses over its 9-period signal line while RSI(14) is at or above 50.
  2. After a stop or target exit, no new entry is taken until an exit signal clears the internal long flag.

Exit rules

  1. MACD(12,26,9) crosses under its signal line while the histogram is at or below 0.
  2. A 2.5% stop loss and an 11.5% profit target are set from the entry price.

Test conditions

PeriodUp to 2026-10-12
InstrumentDAX 40, 4 hours
Spread3 points
Starting capital1,000,000
CostsSpread only. Commissions and overnight financing are not included.
BarsUp to 200,000 bars, fewer where the instrument has less history
Last tested2026-10-12

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
DAX 40Best run4 hours1.22 1,40232.6713,117 EUR-2,222
USD/JPYDailyn/a 65326.80549,510 USD-480,250
EUR/USD3 minn/a 10,18418.99291,267 USD-99,343
EUR/USD2 minn/a 10,26317.30230,115 USD-121,455
EUR/USD5 minn/a 10,05019.47186,867 USD-66,999
Nikkei 225Dailyn/a 55032.9133,377 USD-9,507
SilverDailyn/a 60924.1423,005 USD-8,018
Dow JonesDailyn/a 68835.7618,813 EUR-5,486
Nikkei 2254 hoursn/a 1,20230.3714,692 USD-10,766
DAX 40Dailyn/a 71934.3510,426 EUR-2,720
Nasdaq 1004 hoursn/a 1,43532.068,401 EUR-3,510
GBP/USDDailyn/a 66329.418,127 USD-4,361
Brent CrudeDailyn/a 27230.157,312 EUR-3,643
Nasdaq 100Dailyn/a 54832.666,248 EUR-5,126
US Crude OilDailyn/a 56028.215,811 EUR-5,617
Brent Crude4 hoursn/a 82730.833,805 EUR-3,187
US Crude Oil4 hoursn/a 1,05431.403,708 EUR-3,077
GoldDailyn/a 67828.472,063 EUR-674
Gold4 hoursn/a 1,42530.531,817 EUR-1,251
S&P 500Dailyn/a 71331.841,524 EUR-869

Charts

Results by run

Top 10 of 20 runs. The full list is in the table above.

Net profitMax drawdown

The code

ProBuilder code, as tested

// ==============================================================
// RSI MACD Midline Cross Long
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Momentum
// Direction: Long only
// Timeframe tested: 4 hours
// ==============================================================

DEFPARAM CumulateOrders = false

ONCE inlong = 0

myRsi = RSI[14](close)
myMacd = MACDline[12,26,9](close)
signal = ExponentialAverage[9](myMacd)
hist = myMacd - signal

22 more lines: the entry and exit rules.

Setup

How to load it

  1. Copy the code with the copy button on the code block.
  2. In ProRealTime, open a chart of the instrument and timeframe you want to test, then open ProOrder > New trading system and choose "Create with programming".
  3. Paste the code, give the system a name and save it.
  4. Click "Backtest", set your own spread and position size, and run it before you consider trading it live.

Indicators used

RSIMACDEMA
Read this firstKnown weaknesses2 points
  • Results include the spread only. Commissions and overnight financing are not included.
  • The code is published as it was backtested and has not been compiled again since.

Questions

About this strategy

Can I run RSI MACD Midline Cross Long in ProOrder?

Yes. The code is ProBuilder and runs as an automated ProOrder system. Backtest it on your own account with your own spread and position size before trading it live.

Which markets was it tested on?

It was tested on 20 market and timeframe combinations. The best run was DAX 40, 4 hours, with a profit factor of 1.22 over 1,402 trades.

How large was the drawdown?

The best run had a maximum drawdown of 2,222 EUR at the tested position size, against a net result of 13,117 EUR.

Does it trade long, short or both?

It only takes long trades.

Related

Strategies like this one

Trend Surfer

Uses the same indicator.

1.04 PF · 10,813 trades

Heikin Ashi Color Flip

Best run on the same market, DAX 40.

1.12 PF · 3,692 trades

Reversal Pattern With Dynamic Momentum Index

Also a momentum strategy.

1.23 PF · 1,206 trades

Get the full rules, the complete code and the ProRealAlgos portfolio as a member.

The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.

Past backtest results do not guarantee future results. This is not financial advice. Curated and maintained by ProRealAlgos. ProRealTime™ is a trademark of ProRealTime SAS. prorealalgos.comStatsDocs