Gift Nifty Close Price

subha
Hi,
Is there any api to get previous day close price of Gift Nifty?
Close price using this api
kite.historical_data(291849, stTime, edTime, 'day') doesn't match with the one displayed in Zerodha.
Or
Is there any specific time that we need to get the previous day price?
  • subha
    I see kite.quote giving the previous day close price.
    kite.quote(['NSEIX:GIFT NIFTY'])['NSEIX:GIFT NIFTY']['ohlc']['close']
    But why is kite.historical api (interval='day') data doesn't match with that of kite.quote
  • subha
    Hi,
    kite.historical_data(291849, stTime, edTime, 'day') data does not match with that of kite.quote
    date open high low close volume
    0 2025-05-29 00:00:00+05:30 24762.5 24990.5 24658 24918.5 0
    1 2025-05-30 00:00:00+05:30 24950.0 24975.5 24801 24897.0 0

    whereas kite.quote(['NSEIX:GIFT NIFTY'])['NSEIX:GIFT NIFTY']['ohlc']['close']
    24908.5

    Is there any particular time that the previous close price needs to be checked for?
    Can someone help with this?
  • Nivas
    The GIFT Nifty Index operates in two trading sessions: the first from 6:30 a.m. to 3:40 p.m., and the second from 4:35 p.m. to 2:45 a.m. the following day, as per IST.

    The Quote API provides live market data at the time of the request, provided the market is open. In contrast, the historical_data API returns historical data.

    To retrieve the previous day's close price, you can use the historical_data API. This value should align with the corresponding candle on the Kite chart.
  • subha
    kite.quote(['NSEIX:GIFT NIFTY'])['NSEIX:GIFT NIFTY']['ohlc']['close'] - When I run this now gives a value 25158 which is previous day close price.

    kite.historical_data(291849, datetime.datetime(2025, 6, 6, 9, 15), datetime.datetime(2025, 6, 7, 2, 50), 'day') - this gives 25153.5 as the previous close price.

    There is a discrepancy. Please guide.
Sign In or Register to comment.