QuantsappFaster in the app: live data, alerts, tradingOpen
Log inStart free
Stock F&OPositionalBANKNIFTYmedium complexity

Index vs NIFTY ratio trade

This is a relative-value trade between two indices. Banking stocks make up a large part of NIFTY, so BANKNIFTY and NIFTY usually move together, and their price ratio drifts within a range. When the ratio of their futures stretches two standard deviations from its one-year average, the strategy buys the index that looks cheap and sells the other, holding both in one position until the ratio returns.
Watches the BANKNIFTY to NIFTY futures ratio and, when it stretches two standard deviations from its one-year average, buys the cheap index and sells the rich one in value-matched lots.
Market viewFades moves (mean reversion)
TradesBANKNIFTY vs NIFTY near-month futures, value-matched
RiskOpen-ended (loss not capped by the structure)
CapitalFutures margin
SuitsIntermediate
Trades a month0.5
Typical hold15 days
Profitable months2 of 12
Longest losing run3 trades
Made money inToo few trades (6) to judge any condition
Lost money inToo few trades (6) to judge any condition
Default settings
Symbol
Symbol base
Entry mode
Entry z
Exit z
Stop z
Support band %
Stop ratio %
Target ratio %
Max hold days
Exec time
Roll time
Lots num
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
BANKNIFTY Positional · 1 Oct 25 → 30 Sep 26
Enters
09:20 next session after the log ratio's z-score closes beyond ±2.0
Legs
BUY FUT · Near month (the cheap index of the ratio) · Current month · 1 lotSELL FUT · Near month (the rich index, value-matched lots) · Current month · 1 lot
Exits
target z-score back to 0; closed at 09:20 next sessionstop z-score stretches to 3.5 or beyondtime Held more than 20 sessionsroll Both legs closed 15:15 on monthly expiry, reopened next session at 09:20
Re-entry
Yes - a fresh signal once the previous ratio trade has closed
Ratio
R = SYMBOL's near-month futures close / NIFTY's, per session, as of the previous close.
Entry
ENTRY_MODE "zscore" - z = (log R - its LOOKBACK_DAYS mean) / its deviation; z <= -ENTRY_Z -> long the ratio (buy SYMBOL, sell NIFTY); z >= +ENTRY_Z -> short the ratio. ENTRY_MODE "support_low" - R at or below (1 + SUPPORT_BAND_PCT %) x its SUPPORT_LOOKBACK-session low -> long the ratio; at or above (1 - SUPPORT_BAND_PCT %) x its high -> short the ratio. Executed at EXEC_TIME of the next session, both legs in ONE position (tagged long / short ratio). Lots: LOTS_NUM of SYMBOL against the NIFTY lots whose contract value is closest (the source's 3 BANKNIFTY : 2 NIFTY, re-computed from today's lot sizes).
Exit
zscore - target: z back to EXIT_Z (long: z >= -EXIT_Z; short: z <= EXIT_Z); stop: |z| >= STOP_Z; time: MAX_HOLD_DAYS sessions. support - target: R moves TARGET_RATIO_PCT % in favour; stop: R moves STOP_RATIO_PCT % against; time: MAX_HOLD_DAYS sessions. Exits are decided on the close and executed at EXEC_TIME of the next session.
Roll
both legs close together on the expiry day at ROLL_TIME and re-open at the next session's EXEC_TIME.
2

Results

PRE-BUILT · DEFAULTS
BANKNIFTY · 2025-10-01 → 2026-09-30 · 6 trades · before costs
Net P&L+₹26,372
Win rate33%
Max drawdown−₹40,334
Avg per trade+₹4,395
Profit factor1.58
Worst trade−₹18,598
3

Where it made and lost money

The sample is too small to judge which market conditions suit this trade: it logged only 6 trades in the year, and no condition had the 8 needed for a reading. For the record, the one trade entered on a choppy, wide-range session made ₹61,996, while 4 trades entered on quiet sessions lost ₹30,522. Because one leg is long and the other short, the trade bets on BANKNIFTY moving relative to NIFTY rather than on the market's direction, but value-matching in whole lots never removes market exposure completely.

India VIX the evening before
VIX below 11.5 (calm)−₹4,8341 trades0% won
VIX 11.5-14.5 (normal)+₹36,3084 trades50% won
Kind of session on the entry day
Quiet session (range under 0.75%)−₹30,5224 trades25% won
Choppy day (wide range, closed mid-range)+₹61,9961 trades100% won
Market while the trade was held
NIFTY rose over 1% while held−₹18,5981 trades0% won
NIFTY within ±1% while held+₹9,8121 trades100% won
NIFTY fell over 1% while held+₹40,2603 trades33% won
How the entry day opened
Gap up of 0.4% or more+₹53,2103 trades67% won
Flat open−₹16,9021 trades0% won
Gap down of 0.4% or more−₹4,8341 trades0% won
Session direction on the entry day
NIFTY closed above its open−₹25,6883 trades33% won
NIFTY closed below its open+₹57,1622 trades50% won
Trend going in
Uptrend (NIFTY above its 20-day average)−₹7,0902 trades50% won
Downtrend (NIFTY below its 20-day average)+₹38,5643 trades33% won
Day of the week
Monday−₹4,8341 trades0% won
Wednesday+₹36,3084 trades50% won
The same trades, split by the market conditions around each entry, before costs.
4

About this strategy

  1. Each evening, divide BANKNIFTY's near-month futures close by NIFTY's and take the log of the ratio.
  2. Compare it with the last 250 sessions to get a z-score.
  3. If the z-score is -2 or lower, buy 1 lot of BANKNIFTY futures and sell the NIFTY lots closest in contract value at 09:20 next session; at +2 or higher, do the reverse. Both legs sit in one position.
  4. Close at 09:20 after the z-score returns to 0 (target), reaches 3.5 (stop), or after 20 sessions.
  5. On monthly expiry both legs close at 15:15 and reopen in the next month at 09:20 the following session.
  6. A second entry mode, support_low, instead trades the ratio near its 500-session low or high, with a 5% target and 2.5% stop on the ratio.

Why traders use it

Many traders chart BANKNIFTY against NIFTY to judge whether banks are leading or lagging the market. When the gap looks extreme, a ratio trade lets them bet on it narrowing without taking a strong view on the market's direction, since a broad rise or fall lifts or drops both legs. Using two liquid index futures keeps slippage lower than in stock pairs, and the idea extends to any F&O stock against NIFTY.

Works best whenIn principle, when BANKNIFTY and NIFTY drift apart for a few weeks and then converge. In this test one trade entered on a choppy, wide-range day produced most of the profit, but 6 trades are too few to call any condition reliable.
Struggles whenWhen the gap between banks and the broad market keeps widening, as in a sustained sector re-rating, so the ratio trends instead of reverting. In this test quiet entry sessions lost money, but the sample is too small to rely on.

The year in plain words

On default settings from 1 Oct 2025 to 30 Sep 2026 the ratio trade made ₹26,372 before costs and ₹22,219 after ₹20 per order and bid-ask slippage, from just 6 trades. Only 2 of them won, but the best one, in March, made ₹61,996 while the largest loss was ₹18,598; the profit factor was 1.58 before costs. No trade reached its z-score target or stop: three ended at a monthly roll and three at the 20-session time exit. February lost ₹35,500 and the drawdown reached ₹40,334. With so few trades, the result rests largely on one winner.

What the settings do

Symbol baseThe index in the denominator of the ratio, NIFTY by default. The numerator is the main symbol, which can be a sector index or an F&O stock.Entry modezscore trades the ratio when it is stretched from its average; support_low trades it near its 500-session low or high instead, with percentage target and stop.Lookback daysSessions used for the ratio's average and deviation in the z-score. Shorter windows react faster and signal more often.Entry zHow stretched the ratio must be to open a trade. Lower values trade more often on smaller gaps.Exit zThe z-score at which the trade takes profit on the way back. Zero waits for a full return to the average.Stop zCloses the trade if the ratio keeps stretching to this z-score.Support lookbackIn support_low mode, how many sessions define the ratio's low and high.Support band %In support_low mode, how close to the low or high the ratio must be, in percent, to trigger a trade.Stop ratio %In support_low mode, the percentage move of the ratio against the trade that closes it.Target ratio %In support_low mode, the percentage move of the ratio in favour that takes profit.Max hold daysThe longest a trade is held, in sessions, if neither target nor stop is reached. In this test it closed half the trades.Exec timeThe time next morning at which entries, exits and post-roll re-entries are placed.Roll timeThe time on monthly expiry day at which both legs are closed before reopening in the next month.Lots numLots of the numerator (BANKNIFTY by default); the NIFTY lots are chosen to match its contract value.

Risks

  • The ratio can trend for months when banks lead or lag the market, and the 3.5 z-score stop is wide.
  • Whole-lot value matching leaves some net long or short market exposure on every trade.
  • With only a few trades a year, one or two outcomes decide the whole result, as the ₹61,996 winner did here.
  • Monthly rolls close and reopen both legs, adding orders, slippage and an overnight gap with no position.

Who it suits

Traders who already follow the BANKNIFTY to NIFTY relationship, have margin for two index futures positions at once, and are comfortable with very few trades a year and results driven by a handful of outcomes.

5

Questions traders ask

Is the BANKNIFTY vs NIFTY ratio trade profitable?

In this test it made ₹26,372 before costs and ₹22,219 after ₹20 per order and bid-ask slippage from 1 Oct 2025 to 30 Sep 2026, with statutory charges excluded. That came from only 6 trades, and one winner of ₹61,996 did most of the work, so the evidence is thin. Past results do not guarantee future ones.

How many NIFTY lots hedge one BANKNIFTY lot?

The code values one BANKNIFTY lot (30 units) at the current futures price and sells the number of NIFTY lots (65 units each) whose contract value is closest, with at least one. The number is recomputed at every entry and roll from that day's prices and lot sizes, so it can change over time.

Can I use a stock instead of BANKNIFTY?

Yes. The numerator can be any F&O stock or sector index with futures, traded against NIFTY futures. The same z-score rules then decide when the stock looks stretched relative to the market. Results for other symbols would need their own backtest.

Why did no trade hit its target or stop?

In this year the ratio did not return to its average or stretch to 3.5 deviations before the trade was cut. Three trades ended at a monthly roll, where both legs are closed at 15:15 on expiry day, and three at the 20-session time limit.

6

Before you rely on it

WATCH OUTdiscretionary ratio-chart ideas with no stops and one worked example; whole-lot rounding; four fills per round trip plus rolls. Gross of costs.
WHERE THE RULES WERE UNCLEAR · OUR CHOICES- "Ratio at a 2-year low / support" is not formula-defined; the spec's z-score of the log ratio against its 250-session mean (enter |z| > 2, exit at 0 or after 20 sessions, stop |z| > 3.5) is the default, and the merged variant's 500-session low/high band (1%, stop 2.5%, target 5%) is ENTRY_MODE "support_low". - Lot sizes in the source (NIFTY 75, BANKNIFTY 25) are outdated; lots come from the exchange's table on the trade date. Whole-lot rounding leaves some net market exposure; beta weighting is not applied.
Also known asbanknifty nifty ratio spreadstock vs nifty pairrelative strength ratio tradeIndex/stock-vs-NIFTY relative value: BANKNIFTY/NIFTY (or stock/NIFTY) ratio at support or channel break -> long numerator futures / short NIFTY futures, value-matched lotsbanknifty nifty ratio traderelative value index futures
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.