Quick answer
Kite Connect is Zerodha’s official REST and WebSocket API for NSE, BSE and MCX: orders, positions, holdings, GTT, live ticks and historical candles. Every day you log in through the Kite login page to get a request token, exchange it (with a SHA-256 checksum of api_key + request_token + api_secret) for an access token, and use that until it expires the next morning. A free Personal plan covers orders without market data; the paid Connect plan adds live and historical data.
Zerodha Kite Connect API at a glance
- Pricing
- Personal plan free (no data); Connect plan with data is paid
- Availability
- Indian residents with a Zerodha account
- Paper trading
- No sandbox
- Integration type
- OAuth login
- In AlgoGP
- Design and backtest in AlgoGP, connect the exported code
- Auth
- Daily login → request_token → access_token
- Checksum
- SHA-256 of api_key + request_token + api_secret
- Plans
- Personal (free, no data); Connect (paid, with data)
- SDKs
- Official Python, Java, Node, Go, .NET, PHP
- Order limits
- Exchange-mandated rate limits; static IP for orders
The daily login
import os
from kiteconnect import KiteConnect
kite = KiteConnect(api_key=os.environ["KITE_API_KEY"])
print(kite.login_url()) # open, log in, copy request_token from the redirect
session = kite.generate_session("REQUEST_TOKEN", api_secret=os.environ["KITE_API_SECRET"])
kite.set_access_token(session["access_token"])
print(kite.margins("equity")["net"])Build a Zerodha Kite Connect strategy with AlgoGP
AlgoGP does not connect to Zerodha Kite Connect natively yet. Zerodha Kite Connect authenticates with a browser OAuth login and refreshable tokens, so it needs a one-time manual login step that generated code cannot do on its own.
- 1
Design and backtest in AlgoGP
Describe the strategy to the copilot and backtest it on years of normalized history. The result does not depend on any vendor.
- 2
Export the Python project
Every project exports
strategy.py,market_data.py,brokers.pyandlive.py. The strategy only sees bars, cash, positions and orders, never a vendor’s wire format. - 3
Plug in Zerodha Kite Connect
Implement the four adapter methods (
account,positions,submit_market_orderand a candle fetcher) with Zerodha Kite Connect’s SDK, or keep a built-in platform for paper trading and add Zerodha Kite Connect when you go live.
Built-in brokers for the same markets: Alpaca, Tradier, Interactive Brokers, OKX.
Zerodha Kite Connect API: frequently asked questions
Is Kite Connect free?
The Personal plan (orders, no market data) is free; the Connect plan with live and historical data is paid monthly.
Can I avoid the daily login?
No. Access tokens expire each morning; automate the login only within Zerodha’s terms.
Does Kite Connect have a sandbox?
No; test with small quantities or simulate in AlgoGP first.
Design and backtest your Zerodha Kite Connect strategy first
AlgoGP turns an idea into Python and tests it on years of history before you connect it to Zerodha Kite Connect. The exported code keeps the broker behind four small adapter methods.
- AI copilot writes and revises the rules
- Backtests with realistic costs
- Exported Python ready to wire to Zerodha Kite Connect
Free plan, no card required.
Zerodha Kite Connect alternatives
- Upstox API GuideUpstox Developer API: free REST and WebSocket trading and market data for Indian equities and F&O, with daily OAuth tokens.
- Angel One SmartAPI API GuideAngel One’s free SmartAPI for Indian equities, F&O and commodities: log in with client code, PIN and a TOTP, then trade over REST.
- Dhan (DhanHQ) API GuideDhanHQ API v2: free order APIs for Indian equities, F&O and commodities with a client id and access token; market data paid.
- FYERS API GuideFYERS API v3: free trading, quotes and history for Indian markets, with an app id, secret and a daily OAuth access token.
Independent guide. AlgoGP is not affiliated with Zerodha Kite Connect. Limits, prices and availability change; confirm them in the official documentation. Nothing here is investment advice.