QuantsappFaster in the app: live data, alerts, tradingOpen
Log inStart free
Futures · technicalPositionalNIFTYlow complexity

MACD zero-cross breakout

This positional NIFTY futures strategy uses the MACD line's zero cross as a regime switch and a candle breakout as the trigger. When the daily MACD line crosses above zero, that day's high becomes the level to buy above; when it crosses below zero, the day's low becomes the level to sell below. The trade stays on until MACD crosses back or the signal candle's far side is hit.
When the daily MACD line on NIFTY futures crosses zero, trades the first break of that day's high or low, with the stop at the other end of the candle.
Market viewEither direction (follows the move)
TradesNIFTY near-month futures, 1 lot
RiskOpen-ended (loss not capped by the structure)
CapitalFutures margin
SuitsIntermediate
Trades a month0.9
Typical hold4 days
Profitable months3 of 12
Longest losing run4 trades
Made money inNIFTY falling over 1% while held (3 trades)
Lost money inNIFTY rising over 1% while held (2 trades)
Default settings
Symbol
Fast
Slow
Sides
Roll time
Lots
Backtest this strategy →Change any setting, pick your own period and run it in the Quantsapp web app. Backtesting is part of the Max plan. Pro+ members can use it now as a free trial.
1

How it trades

What it trades
Universe
NIFTY Positional · 1 Oct 25 → 30 Sep 26
Enters
First tick beyond the high (low) of the day the daily MACD line crossed above (below) zero
Legs
BUY FUT · near month · Near month, rolled each expiry · 1 lotSELL FUT · near month · Near month, rolled each expiry · 1 lot
Exits
stop Other end of the signal candlesignal MACD line crosses back through zero: out at the next session's first tickroll Futures expiry day 15:15: closed and reopened next month
Re-entry
None until the next MACD regime
MACD
MACD line = EMA(FAST) - EMA(SLOW) of the daily closes of the rolled near-month future (EMAs seeded with their simple average). Only the line is used; there is no signal-line rule.
Regime
bull from the close where the line crosses above 0 (that day is the signal candle; its high and low are stored) until the close where it crosses below 0; bear is the mirror.
Entry
on a later session, still in that regime as of the previous close, the first futures tick above the signal candle's high buys LOTS (a resting buy-stop; a gap above fills at the gap). Only the first breakout of a regime is traded. SIDES "both" also sells the first tick below a bear signal candle's low.
Stop
the signal candle's low (long) / high (short).
Exit
the line crosses back through 0 -> out at the next session's first tick.
Roll
on the futures expiry day the position is closed at ROLL_TIME ("monthly roll") and re-opened on the new near month at the next session's first tick, keeping the same stop.
Re-entry
none until the next regime.
2

Results

PRE-BUILT · DEFAULTS
NIFTY · 2025-10-01 → 2026-09-30 · 11 trades · before costs
Net P&L+₹1,23,265
Win rate36%
Max drawdown−₹1,53,042
Avg per trade+₹11,206
Profit factor1.58
Worst trade−₹98,553
3

Where it made and lost money

With 11 trades no condition can be judged reliably, and the year's profit rests on the short side. The 3 trades held while NIFTY fell more than 1% made ₹3,27,210, led by the March 2026 short: a MACD cross below zero followed by a break of the signal candle's low caught a sustained decline. The 2 trades held while NIFTY rose more than 1% lost ₹1,45,620, and the 4 held through a market that moved less than 1% lost ₹44,715, mostly on the signal-candle stop. Entries made while NIFTY was below its 20-day average made ₹1,65,938 over 8 trades.

India VIX the evening before
VIX below 11.5 (calm)+₹99,0073 trades67% won
VIX 11.5-14.5 (normal)+₹1,65,5095 trades40% won
VIX above 14.5 (nervous)−₹1,41,2513 trades0% won
Kind of session on the entry day
Quiet session (range under 0.75%)+₹62,4783 trades67% won
Trend day (closed near the high or low)−₹44,4944 trades25% won
Choppy day (wide range, closed mid-range)+₹1,05,2804 trades25% won
Market while the trade was held
NIFTY rose over 1% while held−₹1,45,6202 trades0% won
NIFTY within ±1% while held−₹44,7154 trades0% won
NIFTY fell over 1% while held+₹3,27,2103 trades100% won
How the entry day opened
Gap up of 0.4% or more+₹80,7884 trades50% won
Flat open+₹39,0055 trades20% won
Gap down of 0.4% or more+₹3,4712 trades50% won
Session direction on the entry day
NIFTY closed above its open−₹1,02,3445 trades0% won
NIFTY closed below its open+₹2,25,6096 trades67% won
Trend going in
Uptrend (NIFTY above its 20-day average)−₹42,6743 trades0% won
Downtrend (NIFTY below its 20-day average)+₹1,65,9388 trades50% won
Expiry day (NIFTY weekly)
Expiry day−₹42,6992 trades0% won
Other days+₹1,65,9639 trades44% won
Day of the week
Monday+₹25,8251 trades100% won
Tuesday−₹42,6992 trades0% won
Wednesday+₹1,64,5085 trades60% won
Thursday−₹11,7911 trades0% won
Friday−₹12,5792 trades0% won
The same trades, split by the market conditions around each entry, before costs.
4

About this strategy

  1. Each day, compute the MACD line (12-day EMA minus 26-day EMA) from the daily closes of the near-month NIFTY future.
  2. When the line crosses above zero at a close, a bull regime starts and that day's high and low are stored; a cross below zero starts a bear regime the same way.
  3. On a later session, still in the regime, buy one lot on the first tick above the signal candle's high (or sell on the first tick below its low in a bear regime).
  4. Place the stop at the other end of the signal candle.
  5. Exit at the next session's first tick after MACD crosses back through zero.
  6. On each futures expiry day, close at 15:15 and reopen in the next month with the same stop; only one breakout is traded per regime.

Why traders use it

The MACD line crossing zero means the faster average has moved above or below the slower one, a classic sign that the trend has changed. Waiting for price to break the signal day's high or low asks the market to confirm that change before entering. The signal candle also gives a natural stop. Because it works on daily bars and needs one check a day, it suits traders who cannot watch screens during market hours.

Works best whenIn this test, sustained falls: the 3 trades held while NIFTY dropped more than 1% made all the profit, as a bear regime and a break of the signal candle's low caught a steady decline with no snap-back to the stop.
Struggles whenRallies against a short and markets that go nowhere: trades held while NIFTY rose more than 1% or moved less than 1% all lost, mostly when price reversed through the signal candle and hit the stop.

The year in plain words

On NIFTY from 1 Oct 2025 to 30 Sep 2026 the strategy logged 11 trades, four of them monthly rolls. Only 4 made money, but the average win (₹83,988) was nearly three times the average loss (₹30,384). Net P&L was ₹1,23,265 before costs and ₹1,16,347 after ₹20 per order and slippage, with a ₹1,53,043 drawdown before costs. One trade did most of the work: a short that made ₹2,17,665 in March 2026, while April lost ₹1,18,898. Remove that trade and the year is a loss, which is typical of trend-following.

What the settings do

FastThe length of the faster EMA in the MACD line. A shorter value makes zero crosses earlier and more frequent.SlowThe length of the slower EMA. A longer value makes the regime steadier but slower to turn.SidesBoth trades long and short regimes; long_only ignores bear regimes. In this period the short side produced most of the profit.Roll timeThe time on futures expiry day when the position is closed and reopened in the next month.

Risks

  • The result depends on one or two large trends a year; without them, the strategy loses.
  • The stop is a full daily candle away and positions are held overnight, so gaps can make losses larger.
  • The MACD line is computed on unadjusted rolled futures prices, so a roll's price jump can affect it.
  • Long gaps between signals mean long stretches with nothing happening and a deep drawdown before a winner.

Who it suits

Positional futures traders who check the market once a day, can hold a NIFTY lot overnight for weeks, and accept a low win rate and large drawdowns in exchange for occasional big trend trades.

5

Questions traders ask

What is the MACD zero line cross?

The MACD line is the 12-day EMA minus the 26-day EMA. When it crosses above zero, the short-term average has moved above the longer one, read as the start of an uptrend; a cross below zero is read as a downtrend.

Is the MACD zero cross strategy profitable on NIFTY?

In this backtest from 1 Oct 2025 to 30 Sep 2026 it made ₹1,23,265 before costs and ₹1,16,347 after ₹20 per order and bid-ask slippage, but most of it came from one short trade in March 2026. With 11 trades the result is fragile, and past results do not guarantee future ones.

Why wait for a breakout of the signal candle?

The zero cross is based on closing prices and often whipsaws. Requiring price to break the high (or low) of the day the cross happened adds confirmation, and that candle's other end provides a clear stop level.

Can the strategy be run long only?

Yes. Setting the sides option to long only ignores bear regimes. In this period that would have removed the biggest winning trade, which was a short.

6

Before you rely on it

WATCH OUTthe template is SBIN cash, not index futures. The daily closes are the rolled future's, unadjusted, so a roll's basis jump feeds the EMAs. Gross of costs.
WHERE THE RULES WERE UNCLEAR · OUR CHOICESThe source exits only on the bear flip, has no price stop and computes but never uses the short side. As the spec's interpretation says, the short side is added (SIDES) and the signal candle's far side is the stop. The template fills at the signal close; here the entry is the breakout tick on a LATER session and the exit the next session's first tick after the closing cross.
Also known asMACD zero line breakout
Backtests run on historical NSE data with fills at the last traded price. "Before costs" excludes brokerage, taxes and slippage. Quantsapp is not recommending any strategy; it is just a backtesting utility. Past results are not a promise of future returns.

Log in or sign up

Enter your mobile number. New to Quantsapp? The same OTP creates your free account.

+91

By continuing you agree to the Terms of Use and Privacy Policy.