Bank Nifty Historical Data in Excel

In this article

Retrieve Bank Nifty historical candles in Excel with MarketXLS India and a connected Zerodha or Angel One account. Select a date range for a historical table, or use Candles for a rolling view that updates.

See it in actionMarketXLS video
View current plans

Try it in your own spreadsheet

Get the free MarketXLS sample workbook (.xlsx).

No account needed. MarketXLS live data requires a paid plan. Preview workbook

Bank Nifty Historical Data in Excel - MarketXLS

Get MarketXLS India: plans and subscription · See the India Excel add-in

Start with this formula

After connecting the required broker in the India add-in, enter:

=MXLSIN.ZerodhaHistory("BANKNIFTY", "day", "2026-01-01 09:15", "2026-03-31 15:30")

Use the example as a starting point and replace its instrument, date range or cell references with your own inputs. Historical dates in examples are sample periods; expiry-specific symbols must refer to a valid contract.

Set up the worksheet

  1. Open Excel and install MarketXLS India from the add-in marketplace.
  2. Sign in with your MarketXLS India account. For broker data, connect Zerodha or Angel One using the add-in panel. Use the broker named by a broker-specific formula.
  3. Enter the formula in an empty area. Leave adjacent cells clear for any table or multi-cell output.
  4. Confirm the instrument and settings before extending the worksheet.

Put the index symbol, interval and date range in input cells above the data. Start with daily history for a short period, confirm the returned dates, then request the intraday interval you need. Keep the returned table clear of notes so Excel can spill every row.

Build the working example

For a range study, subtract Low from High on each row and chart the result. For returns, divide each close by the previous close and subtract one. These answer different questions: a wide daily range does not necessarily mean a large close-to-close move.

Functions and syntax

These examples use the India namespace, MXLSIN.. Square brackets in a syntax line indicate optional arguments; do not type the brackets into Excel. Keep text arguments in quotation marks and use cell references when you want editable inputs.

ZerodhaHistory

Returns historical OHLCV candles for a stock, index, future or option from Zerodha. Intervals from 1 minute to daily.

Syntax:

MXLSIN.ZerodhaHistory(symbol, interval, fromDate, toDate)

Example:

=MXLSIN.ZerodhaHistory("BANKNIFTY", "day", "2026-01-01 09:15", "2026-03-31 15:30")

AngelOneHistory

Returns historical OHLCV candles for a symbol from Angel One. Intervals from 1 minute to daily.

Syntax:

MXLSIN.AngelOneHistory(symbol, interval, fromDate, toDate)

Example:

=MXLSIN.AngelOneHistory("SBIN", "day", "2026-01-01 09:15", "2026-03-31 15:30")

Candles

Spills the last N candles (Date, Open, High, Low, Close, Volume, OI) from your connected broker and keeps them updating.

Syntax:

MXLSIN.Candles(symbol, [interval], [bars], [mode], [broker])

Example:

=MXLSIN.Candles("BANKNIFTY", "15m", 50)

Check the result

Use the Bank Nifty index when studying the index itself. A Bank Nifty futures contract has an expiry and a different price series; it is not interchangeable with index history. Available history depends on your broker and the requested interval.

If Excel reports #NAME?, confirm the India add-in is loaded and the function name is spelled correctly. If a table reports #SPILL!, clear the cells in its output area. For missing broker data, check the connection in the add-in panel, verify the symbol, and test one request before expanding the sheet. Do not replace an error with zero when zero would change your analysis.

Can I get five-minute history?

Choose a supported intraday interval in the history function. Check the broker's available dates first; a daily-history request does not establish the same depth of intraday history.

Get this working in your Excel

Choose a MarketXLS India subscription, install the India add-in, and follow the steps above. The pricing page lists the current subscription options; broker access requirements are separate from the spreadsheet formulas.

Use the India function library for the complete parameter reference, or contact the India team with the formula, instrument and error message if you need setup help. Never send broker passwords or access tokens.

Continue with the India Excel workflow series for related guides.

About the authors
Ankur

About Ankur

CEO & Founder, MarketXLS

Ankur is the CEO and founder of MarketXLS. He works with Anagh and Robin on the MarketXLS blog, creating articles together about market data and spreadsheet workflows.

Written collaboratively by Ankur, Anagh and Robin.

Important Disclaimer

The information provided in this article is for educational and informational purposes only and should not be construed as investment advice, a recommendation, or an offer to buy or sell any securities. MarketXLS is a financial data platform and is not a registered investment advisor, broker-dealer, or financial planner. Always conduct your own research and consult with a qualified financial professional before making any investment decisions. Past performance is not indicative of future results. Trading and investing involve substantial risk of loss.

See MarketXLS in action

Bring this workflow into Excel.

Book a demo with our team to see how MarketXLS supports your market research.

Ankur
AnkurFounder & CEO, MarketXLS