5 Minute Intraday

5 Minute Intraday is a trend-pullback strategy built for five-minute candles. It combines a fast and pullback EMA, a slower SMA trend reference, a smoothed measurement of that SMA’s angle, ADX strength, and recent support or resistance.
The strategy buys when the fast EMA is above the pullback EMA, price is above the trend SMA, the trend angle is sufficiently positive, ADX confirms usable movement, and price returns to the fast/pullback EMA “fire zone.”
This method is best suited to liquid intraday markets with a clear, moderately strong trend and orderly EMA pullbacks. It is designed to avoid the flat angle region where direction is unclear.
warning
Protection is disabled by default. FMI_STOP_PIPS and FMI_STOP_PCT define a stop candidate, but it only becomes executable when FMI_STOP_ENABLED is enabled.
The fire-zone entry
FMI_FAST_EMA_LENGTH and FMI_PULLBACK_EMA_LENGTH form the fire zone. With the defaults, these are EMA 10 and EMA 21.
A long setup requires the fast EMA at or above the pullback EMA and price at or above FMI_TREND_SMA_LENGTH. The candle low must reach the EMA zone while the close remains near or above the pullback EMA.
FMI_PULLBACK_PROXIMITY_PIPS gives price a small allowance around the zone in pip mode. In percentage mode, the allowance is fixed at approximately 0.02% of current price, so the pip proximity field no longer changes it.
The strategy opens one position at a time and does not average down.
SMA angle and the no-trade zone
The strategy measures how far the trend SMA has moved over FMI_ANGLE_LOOKBACK, expressed in pips per candle. It then smooths that raw measurement with an EMA using FMI_ANGLE_EMA_LENGTH.
The smoothed angle must exceed a positive threshold for a long entry:
- most pairs use
FMI_ANGLE_THRESHOLD; - EUR/JPY uses
FMI_EURJPY_ANGLE_THRESHOLD.
When the absolute smoothed angle is smaller than the applicable threshold, the strategy considers the market a no-trade zone.
FMI_USE_STRONG_ANGLE_FILTER adds another requirement. When enabled, the unsmoothed angle itself must exceed FMI_STRONG_ANGLE_THRESHOLD. This asks both the broader smoothed direction and the immediate slope to be strong.
These values are tied to pip size. A wrong FMI_PIP_SIZE changes the angle scale as well as targets, stops, proximity, and spread measurement.
ADX confirmation
ADX must be at or above FMI_MIN_ADX.
When FMI_REQUIRE_ADX_RISING is enabled, a short LSMA of ADX must also be flat or rising. FMI_ADX_LSMA_LENGTH controls that smoothing. This is intended to avoid entries when trend strength is already fading.
ADX measures strength, not bullish direction. Direction comes from the EMA/SMA stack and angle filters.
Support and resistance filter
The strategy estimates recent support from the lowest low and recent resistance from the highest high over FMI_SR_LOOKBACK, excluding the current candle.
With FMI_REQUIRE_SR_FILTER enabled, a long close must not be meaningfully below recent support. This blocks entries during a fresh support breakdown. The mirrored short setup must not be meaningfully above recent resistance.
This is a lightweight structural filter, not a guarantee that support will hold.
Spread filters
An entry must satisfy all enabled spread limits:
FMI_MAX_SPREAD_PCTlimits spread as a percentage;FMI_MAX_SPREAD_ABSOLUTElimits spread in USDT for a pair such asUSDT-BTCwhen greater than zero;FMI_MAX_SPREAD_PIPSlimits spread in pips when greater than zero.
The pip limit depends on FMI_PIP_SIZE. With the default value of 0, the strategy uses 0.01 for JPY pairs and 0.0001 for other pairs.
Target and exits
The target uses FMI_TARGET_PIPS in pip mode or FMI_TARGET_PCT in percentage mode. It is adjusted to account for estimated round-trip trading fees.
Three technical exits can close only at break-even or better:
FMI_EXIT_ON_OPPOSITE_SIGNALexits when the complete mirrored short setup appears.FMI_EXIT_ON_NO_TRADE_ZONEexits when the smoothed angle returns inside the neutral zone.FMI_EXIT_ON_EMA_FLIPexits when the fast EMA falls below the pullback EMA.
These exits manage profitable or recovered positions. They do not deliberately realize a loss.
Planned stop level
The strategy calculates a stop candidate from the closest valid level below entry among:
- the configured pip or percentage distance;
- the bottom of the EMA fire zone;
- recent support.
The proximity allowance is placed below the structural references.
FMI_STOP_PIPS and FMI_STOP_PCT control this planned level. Enable FMI_STOP_ENABLED to allow it to execute as a loss-taking protective stop.
Good market conditions
5 Minute Intraday generally works best when:
- the pair is liquid and satisfies all spread filters;
- the fast EMA is clearly above the pullback EMA;
- price remains above the trend SMA;
- the smoothed SMA angle is outside the neutral zone;
- ADX shows sufficient strength;
- a controlled pullback reaches the EMA fire zone without breaking support.
A strong setup often looks like a steady intraday rise, a brief retracement into EMA 10/21, and a close that holds the slower EMA while the broader SMA angle remains positive.
Avoid flat periods where the angle oscillates around zero, weak ADX conditions, and sharp support breaks. A fire-zone touch during a collapsing trend is not the same as an orderly pullback.
Creating the strategy
Create a spot strategy and choose 5 Minute Intraday as the buy and sell method. The default period is five minutes. Begin with backtesting or paper trading.
A practical setup order is:
- Select a liquid pair with reliable five-minute candles.
- Verify automatic or manual pip size.
- Keep the default EMA and SMA structure initially.
- Compare the ordinary and strong angle filters.
- Test ADX level and rising confirmation separately.
- Keep the support/resistance filter enabled for the first tests.
- Set all three spread limits deliberately.
- Evaluate losing positions knowing the exposed stop fields do not activate protection.
Strategy settings
Trading and execution
| Setting | Description |
|---|---|
BUY_ENABLED | Enables new buy orders. |
SELL_ENABLED | Enables target and technical sell orders. |
PERIOD | Candle period used for all calculations; the default is five minutes. |
TRADING_LIMIT | Compatibility fallback only. It is ignored while the strategy-specific trading limit contains a positive value. Configure the strategy-specific setting for normal use. For USDT-BTC, this value is in USDT. |
FMI_TRADING_LIMIT | For USDT-BTC, the amount of USDT used for an entry. |
FUNDS_RESERVE | For USDT-BTC, the amount of USDT the bot must leave unused. |
KEEP_QUOTE | For USDT-BTC, the amount of BTC the strategy must not sell. |
MIN_VOLUME_TO_BUY | General minimum buy value. For USDT-BTC, this value is in USDT. |
MIN_VOLUME_TO_SELL | General minimum sell value. For USDT-BTC, this value is in USDT. |
FMI_MIN_ORDER_VALUE | Strategy-specific minimum entry value. For USDT-BTC, this value is in USDT. |
FMI_MIN_SELL_VALUE | Strategy-specific minimum exit value. For USDT-BTC, this value is in USDT. |
FMI_COOLDOWN_MS | Minimum live-trading delay in milliseconds between actions. It is not applied in backtests. |
FMI_MAX_SPREAD_PCT | Maximum permitted spread as a percentage. |
FMI_MAX_SPREAD_ABSOLUTE | Optional maximum spread in USDT for a pair such as USDT-BTC. 0 disables it. |
FMI_MAX_SPREAD_PIPS | Optional maximum spread in pips. 0 disables it. |
FMI_NEWS_BLOCK | Manually blocks new entries while existing positions remain manageable. |
FMI_NEWS_BLOCK_UNTIL | Blocks new entries until the configured time. |
EMA fire zone and trend
| Setting | Description |
|---|---|
FMI_FAST_EMA_LENGTH | Length of the faster EMA in the pullback zone. |
FMI_PULLBACK_EMA_LENGTH | Length of the slower EMA in the pullback zone; keep it above the fast length. |
FMI_TREND_SMA_LENGTH | Length of the broader trend SMA that price must hold above for longs. |
FMI_PULLBACK_PROXIMITY_PIPS | Fire-zone and structure tolerance in pip mode. Percentage mode uses a fixed proportional allowance. |
Angle filters
| Setting | Description |
|---|---|
FMI_ANGLE_EMA_LENGTH | EMA smoothing length applied to the raw trend-SMA angle. |
FMI_ANGLE_LOOKBACK | Number of candles used to measure the trend SMA’s movement. |
FMI_ANGLE_THRESHOLD | Minimum smoothed angle for most pairs. |
FMI_EURJPY_ANGLE_THRESHOLD | Minimum smoothed angle used specifically for EUR/JPY. |
FMI_STRONG_ANGLE_THRESHOLD | Minimum raw angle when the strong filter is enabled. |
FMI_USE_STRONG_ANGLE_FILTER | Requires the current raw angle as well as the smoothed angle to show strong direction. |
ADX and structure
| Setting | Description |
|---|---|
FMI_ADX_LENGTH | ADX lookback. |
FMI_ADX_LSMA_LENGTH | Smoothing length used to judge whether ADX strength is rising. |
FMI_MIN_ADX | Minimum ADX value for either long or mirrored short setups. |
FMI_REQUIRE_ADX_RISING | Requires the smoothed ADX value to be flat or improving. |
FMI_SR_LOOKBACK | Recent candles used to estimate support and resistance. |
FMI_REQUIRE_SR_FILTER | Blocks longs meaningfully below support and mirrored shorts meaningfully above resistance. |
Target and planned stop
| Setting | Description |
|---|---|
GAIN | General gain fallback retained in the configuration. The strategy normally uses its own target setting. |
FMI_USE_PIPS | Uses pip distances for target, stop, proximity, and related measurements. |
FMI_PIP_SIZE | Value of one pip. 0 selects 0.01 for JPY pairs and 0.0001 otherwise. For USDT-BTC, this value is in USDT. |
FMI_TARGET_PIPS | Target distance in pip mode. |
FMI_STOP_PIPS | Planned stop distance in pip mode. |
FMI_TARGET_PCT | Target percentage when pip mode is disabled. |
FMI_STOP_PCT | Planned stop distance in percentage mode. |
FMI_MIN_NET_GAIN_PCT | Intended gain beyond estimated round-trip fee break-even. |
FMI_STOP_ENABLED | Activates the planned loss-taking protective stop. |
Technical exits
| Setting | Description |
|---|---|
FMI_EXIT_ON_OPPOSITE_SIGNAL | Enables a break-even-or-better exit on the complete mirrored short setup. |
FMI_EXIT_ON_NO_TRADE_ZONE | Enables a break-even-or-better exit when the smoothed angle returns to neutral. |
FMI_EXIT_ON_EMA_FLIP | Enables a break-even-or-better exit when the fast EMA falls below the pullback EMA. |
Backtesting range
| Setting | Description |
|---|---|
BF_SINCE | Start of the selected backtesting period. |
BF_UNTIL | End of the selected backtesting period. |
DEEP_TESTING | Enables deeper backtesting mode in the editor. |
Practical tuning directions
For more signals, reduce the angle or ADX threshold, disable rising-ADX confirmation, or widen the EMA proximity. Each change admits weaker trend conditions.
For cleaner trends, enable the strong raw-angle filter and require rising ADX. This can substantially reduce entries, especially after a trend has begun to mature.
Angle thresholds cannot be transferred safely without the same pip definition. Confirm FMI_PIP_SIZE before interpreting backtest results.
Use the support/resistance filter when you want to reject fresh breakdowns through prior lows. Disabling it makes the EMA fire zone the primary price-structure test.
Important limitations
- Stop-distance fields activate protective selling only when
FMI_STOP_ENABLEDis enabled. - Technical exits do not deliberately close below break-even.
- Angle thresholds depend on pip size and chart period.
- EUR/JPY uses its own threshold; other JPY pairs use the general threshold.
- Percentage mode uses a fixed proximity instead of
FMI_PULLBACK_PROXIMITY_PIPS. - ADX measures strength, not direction.
- Recent support and resistance are simple range extremes and can break.
- Backtests cannot perfectly reproduce live spread, slippage, latency, or liquidity.
5 Minute Intraday is strongest when all parts describe the same event: positive trend angle, adequate strength, bullish EMA order, and a controlled return to the fire zone. If the market is inside the angle no-trade zone, waiting is part of the strategy.