All posts
PublishedByDMI/ADXADXDMI+DI−DItrendindicatorbacktestUSD/JPY

DMI/ADX settings: level 25 removes four in five DI crosses

DMI/ADX periods, thresholds, DI crosses and DI comparison tested in 1,344 USD/JPY runs. The standard 14/25 hourly cross made 101 trades and lost 68.1 pips in 2025.

Directional Movement Index (DMI) puts three lines in one pane: +DI for positive directional movement, −DI for negative directional movement, and ADX for the smoothed separation between them. The DI lines supply direction. ADX uses an absolute difference, so it measures strength without distinguishing an uptrend from a downtrend.

Period 14 with ADX at least 25 is the familiar setup. On USD/JPY in 2025, adding that threshold cut the period-14 DI crosses from 2,184 to 339 on M15, 534 to 101 on H1, and 141 to 19 on H4. Only 13.5% to 18.9% of the crosses remained.

The smaller set was not consistently better. The 14/25 DI cross made money in both years only on M15. H1 lost 68.1 pips in 2025 after gaining 137.5 in 2024. Used as a filter on a 10/20 SMA cross, ADX 25 reduced 2025 net from +377.4 to −922.1 pips.

05001,0001,5002,000M15H1H4number of DI crosses
all DI crossesADX at least 25period 14, 2025
Requiring ADX 25 kept 339 of 2,184 M15 DI crosses, 101 of 534 H1 crosses and 19 of 141 H4 crosses.

What DMI/ADX measures

The calculation starts with changes in consecutive highs and lows.

  1. Measure how far the current high rose above the previous high.
  2. Measure how far the previous low stood above the current low.
  3. Keep only the larger positive move as +DM or −DM.
  4. Divide the smoothed directional moves by true range to produce +DI and −DI.
  5. Calculate DX as |+DI − −DI| ÷ (+DI + −DI) × 100, then smooth DX into ADX.

Taking the absolute value removes direction. ADX at 30 does not mean price is rising. It means the two DI lines have separated.

The MetaTrader 5 ADX documentation describes the basic period-14 rule as buying when +DI is above −DI and selling when −DI moves above +DI. MetaTrader's Wilder calculation reference shows the full sequence from +DM, −DM and true range through DI, DX and ADX.

DMI/ADX settings and signals

DMI is drawn in a separate pane below the candles, with one ADX line and two DI lines. All three run from 0 to 100.

PlatformWhere to find it
MT4 / MT5Insert → Indicators → Trend → Average Directional Movement Index
TradingViewSearch the indicator list for Directional Movement Index (DMI)
Browser (Formiq)Pick ADX from the indicator list

TradingView separates ADX from DMI. Its official DMI reference directs readers to DMI when all three lines are needed. MT4 and MT5 show the three lines together; MT5 also offers a separate ADX Wilder calculation.

Chart settings

FieldDefaultWhat it changes
Period14Smoothing length for +DM, −DM, true range and DX
ADX linePlatform colourTrend strength without direction
+DI linePlatform colourRelative strength of positive directional movement
−DI linePlatform colourRelative strength of negative directional movement
LevelsOptionalReference lines such as 20 or 25

A shorter period reacts sooner and produces more DI crosses. A longer period smooths the lines but reacts later to short trends. Changing the threshold does not change the lines; it changes which signals are accepted.

Backtest settings

FieldDefaultWhat it changes
Period14Number of bars in the DMI/ADX calculation
Minimum25Allows a new entry only while ADX is at or above this level
DirectionFilter onlyKeeps the direction chosen by another rule and adds only the ADX threshold

The direction menu has three choices:

  • Filter only: require the ADX threshold but take direction from another rule, such as a moving-average cross
  • +DI/−DI cross: buy when +DI crosses above −DI and sell on the reverse cross, provided ADX meets the threshold
  • +DI/−DI comparison: while ADX meets the threshold, buy when +DI is higher and sell when −DI is higher; entry does not have to occur on the crossing bar

The sweep treats the last two as separate systems. Filter only is tested by adding it to a 10/20 SMA cross.

How this was measured

ItemValue
PairUSD/JPY
Window2025-01-01 to 2025-12-31, with 2024 run identically for comparison
Timeframes15-minute / 1-hour / 4-hour
Readings+DI/−DI cross / +DI/−DI comparison
Periods5 / 7 / 10 / 14 / 20 / 28 / 40 / 50
Minimum ADX0 / 15 / 20 / 25 / 30 / 35 / 40
Combinations112 per cell; 3 timeframes × 4 windows = 1,344 runs
ExitThe opposite DI signal; entry and exit share the same rule set
Stops and targetsNone in the main sweep, tested separately below
Spread and fill0.3 pips fixed, filled at the close
Size0.1 lot

Level 0 is the no-ADX-filter control. The 2025 sample is also split into two halves so a full-year total cannot hide a reversal within the year.

Level 25 removes more than four in five DI crosses

The table counts period-14 bars above each threshold and the DI crosses that survived level 25.

TimeframeYearADX ≥ 20 barsADX ≥ 25 barsADX ≥ 30 barsAll DI crossesCrosses at ADX ≥ 25
M15202463.65%43.47%27.93%2,136349
M15202561.22%40.51%25.15%2,184339
H1202464.82%44.91%29.49%50193
H1202566.33%47.24%31.40%534101
H4202473.82%50.43%30.45%14235
H4202567.20%37.58%17.58%14119

ADX was at least 25 on 37.58% to 50.43% of all bars, yet only 13.5% to 24.6% of DI crosses met the same threshold. A DI cross marks a change in direction; ADX is a smoothed measure of separation and often remains low on the crossing bar.

The timing mismatch also appears in the slope. At the 2025 crossing bars, ADX was rising on only 218 of 2,184 M15 crosses, 53 of 534 H1 crosses and 11 of 141 H4 crosses.

Only 3 to 16 of 56 settings survived both years

Each reading has eight periods by seven thresholds.

DI cross

TimeframeProfitable 20252025 medianProfitable 20242024 medianProfitable both years
M1517/56−40.1 pips17/56−189.8 pips10/56
H127/560.0 pips19/56−37.9 pips9/56
H46/56−167.1 pips29/56+3.2 pips4/56

DI comparison

TimeframeProfitable 20252025 medianProfitable 20242024 medianProfitable both years
M1518/56−335.5 pips26/56−53.2 pips13/56
H123/56−79.4 pips32/56+118.4 pips16/56
H43/56−817.8 pips38/56+359.2 pips3/56

The H4 DI-comparison grid moved from 38 profitable settings in 2024 to three in 2025. Changing the reading did not remove the timeframe reversal.

Period 14 and level 25 survived only on M15

The default combination produced the following runs.

ReadingTimeframe2025 trades2025 win rate2025 net2024 trades2024 net
DI crossM1533932.45%+141.1 pips349+403.3 pips
DI crossH110133.66%−68.1 pips93+137.5 pips
DI crossH41942.11%+433.3 pips35+152.0 pips
DI comparisonM1568632.65%−391.2 pips679+570.3 pips
DI comparisonH118134.25%−388.5 pips179+72.3 pips
DI comparisonH44524.44%−2,277.2 pips59+1,042.7 pips

The H4 cross was profitable in both years, but only 19 trades occurred in 2025 and 35 in 2024. M15 supplied 339 and 349 trades and stayed profitable. DI comparison changed sign between the two years on every timeframe.

Levels 0 and 15 move more than the boundary at 25

These are hourly marginal means across all eight periods. Settings with no trades remain in the average at zero pips.

DI-cross threshold

Minimum ADXMean net 2025Mean net 2024Mean trades 2025
0−37.4 pips+842.1 pips541.1
15+447.4 pips−320.5 pips381.1
20+231.5 pips−416.4 pips265.6
25+94.6 pips−239.8 pips170.5
30+17.4 pips−120.1 pips101.4
35+7.6 pips−122.5 pips57.8
40+39.5 pips+13.9 pips31.8

Level 0 averaged +842.1 pips in 2024 and −37.4 in 2025. Level 15 reversed the pattern, gaining 447.4 pips in 2025 and losing 320.5 in 2024. Level 40 was positive in both averages, but traded only 31.8 times per setting in 2025. Nothing special happened at 25.

DI-comparison threshold

Minimum ADXMean net 2025Mean net 2024Mean trades 2025
0−84.0 pips+788.4 pips542.1
15−36.1 pips−14.9 pips417.5
20−317.6 pips+52.2 pips326.8
25−215.6 pips+80.9 pips248.1
30−178.2 pips−47.7 pips183.5
35−295.6 pips−107.8 pips136.4
40−138.7 pips+22.3 pips98.8

Every DI-comparison threshold had a negative mean in 2025. Raising the minimum did not recover the loss.

Periods 5 and 7 were the only smoothing lengths with positive hourly marginal means in both years for both readings. The DI-cross means at period 5 were +347.9 pips in 2025 and +225.0 in 2024; period 7 returned +307.1 and +71.2. DI comparison returned +833.4 and +663.0 at period 5, then +437.7 and +476.5 at period 7. The shorter setting also averaged 596.1 cross trades and 729.3 comparison trades in 2025, so its result includes a much larger spread bill.

Four of six 2024 winners lost money in 2025

Each 2024 winner was carried unchanged into 2025.

ReadingTimeframePeriodLevel2024 net2025 net2025 median
DI crossM15280+1,305.0 pips+366.0 pips−40.1 pips
DI crossH1500+1,513.1 pips−1,309.9 pips0.0 pips
DI crossH4200+1,738.5 pips−752.8 pips−167.1 pips
DI comparisonM152020+1,630.4 pips+86.0 pips−335.5 pips
DI comparisonH1500+1,391.5 pips−1,352.7 pips−79.4 pips
DI comparisonH42015+1,677.3 pips−1,329.7 pips−817.8 pips

The two M15 winners remained positive, but retained only 22.4% and 5.3% of their 2024 net. Both H1 and H4 winners fell below their 2025 median under both readings.

A 33.66% win rate can still sit near break-even

The 14/25 hourly DI cross made 101 trades in 2025, won 33.66%, and lost 68.1 pips. Its average win was +54.05 pips and average loss −28.44 pips. Winning only one trade in three nearly broke even because the average win was about 1.9 times the average loss.

The 2025 H4 result looks better at 42.11% and +433.3 pips, but it contains only 19 trades. DI comparison at the same setting made 45 trades, won 24.44%, and lost 2,277.2 pips. Trade count, average win and loss, and annual net are needed alongside the win rate.

ADX reduced profit on a 10/20 SMA cross in both years

Filter only was added to the entry of a 10/20 SMA cross. The exit remained the unfiltered opposite cross.

YearADX entry filterTradesWin rateAnnual net
2025None35839.11%+377.4 pips
2025At least 2019736.55%−80.9 pips
2025At least 2511731.62%−922.1 pips
2025At least 307732.47%−358.8 pips
2024None31541.59%+2,888.4 pips
2024At least 2016942.01%+1,349.6 pips
2024At least 2510648.11%+1,073.2 pips
2024At least 305944.07%+462.8 pips

Level 25 raised the 2024 win rate from 41.59% to 48.11% while cutting net from +2,888.4 to +1,073.2 pips. All three thresholds turned the profitable 2025 baseline into a loss. Waiting for an already strong reading removed profitable early entries as well as losing crosses.

Sessions and exits did not transfer cleanly

The variants use the 14/25 hourly DI cross.

Variant2025 trades2025 net2024 trades2024 net
Baseline101−68.1 pips93+137.5 pips
Tokyo, UTC 0–833−457.5 pips37+351.1 pips
London and New York, UTC 7–2166+511.1 pips56−7.6 pips
Stop 30 / target 6093+603.0 pips87+253.2 pips
Stop 50 / target 10097+612.3 pips87−246.1 pips
Stop 100 / target 200100+170.6 pips90−274.5 pips
Stop 50 / target 5097+700.5 pips88+31.4 pips

The London and New York window gained 511.1 pips in 2025 and lost 7.6 in 2024. Stop 30 / target 60 beat the baseline in both years. It was selected from four tested exit pairs and still needs another period for confirmation.

The 2025 loss remains at zero spread

The 14/25 hourly DI cross lost 37.8 pips at zero spread and 68.1 pips at 0.3. The 30.3-pip difference equals 101 trades times 0.3 pips, so transaction cost alone does not explain the loss.

In 2024, the same rule returned +165.3 pips at zero spread, +137.5 at 0.3, +25.9 at 1.5, and −20.6 at 2.0. Its break-even spread was about 1.78 pips. The losing 2025 run has no positive break-even spread.

Notes

The sample uses USD/JPY in 2024 and 2025, close fills, a fixed 0.3-pip spread and 0.1 lot. ADX(14) needs 28 bars before its first value in this implementation. The main sweep exits on the opposite DI signal; fixed stops and targets are measured separately.

Questions people ask

What are the best DMI/ADX settings?
The common period 14 and level 25 did not produce a universal answer. Its DI cross was profitable in both years on M15, lost 68.1 pips on H1 in 2025, and traded only 19 times on H4 in 2025. Of the 56 hourly settings, nine DI-cross settings and 16 DI-comparison settings were profitable in both 2024 and 2025.
What do ADX levels 20 and 25 mean?
A common reading treats ADX above 25 as a strong trend and below 20 as a weak or absent trend. In this period-14 USD/JPY sample, ADX was at least 25 on 40.51% of M15 bars, 47.24% of H1 bars and 37.58% of H4 bars in 2025. Requiring 25 kept only 339 of 2,184 M15 DI crosses, 101 of 534 H1 crosses and 19 of 141 H4 crosses.
Can ADX tell me whether to buy or sell?
ADX cannot distinguish up from down because it smooths the absolute gap between +DI and −DI. Direction comes from which DI line is higher or from a cross between the two. Formiq's filter-only choice therefore needs another directional rule, such as a moving-average cross.
Should I use a DI cross or DI comparison?
A DI cross enters only when +DI and −DI change order. DI comparison can enter whenever ADX is above the threshold and one line is already higher. On H1 at period 14 and level 25, the cross made 101 trades and lost 68.1 pips in 2025; comparison made 181 trades and lost 388.5. Their 2024 results were +137.5 and +72.3 pips.
Is DMI/ADX built into MT4 and MT5?
Yes. It appears in a separate pane with ADX, +DI and −DI, and the default period is 14. MT5 includes the standard calculation and a Wilder version. Formiq exposes the period, minimum ADX level and three directional choices: filter only, DI cross and DI comparison.

Formiq is a free browser-based FX terminal with replay practice and no-code backtesting. Open the chart or see what the free plan includes.