Why Indian Trading APIs Matter in 2026
If you want to automate any part of your trading — from screening and alerts to full algorithmic execution — you need a broker API. India's brokerage ecosystem has matured significantly, with three APIs dominating the space: Zerodha Kite Connect, 2. Angel One SmartAPI, and 3. Upstox API v2. Each has different pricing, capabilities, rate limits, and documentation quality. Choosing the wrong one costs you time (rewriting code), money (subscription fees), and potentially missed trades (downtime during volatile sessions).
I have built and maintained trading bots on all three platforms since 2023. This comparison is based on production experience, not marketing pages.
1. Zerodha Kite Connect API
Kite Connect is the gold standard for Indian trading APIs. Launched in 2016, it was the first serious attempt to bring developer-friendly trading APIs to India. Most open-source trading libraries, tutorials, and community projects target Kite Connect.
Pricing
Rs 2,000 per month for the API subscription, plus standard Zerodha brokerage (Rs 20 per executed order for intraday/F&O, zero for delivery). The monthly fee is charged regardless of usage — if you subscribe in the middle of the month, you still pay the full Rs 2,000. Historical data add-on costs an additional Rs 2,000/month.
Key Features
- WebSocket streaming: Real-time tick data for up to 3,000 instruments simultaneously. Latency is typically 100-300ms from exchange — adequate for swing and positional trading, tight for scalping.
- Order types: Market, limit, SL, SL-M, GTT (Good Till Triggered), bracket orders, cover orders. The GTT functionality through the API is identical to the Kite web interface.
- Historical data: Minute, 5-min, 15-min, 30-min, hourly, and daily candles. Up to 2 years of minute data and full history for daily data. Requires the Rs 2,000/month historical data add-on.
- Portfolio and positions: Real-time holdings, positions, order book, and P&L APIs.
- Margins: Pre-trade margin calculation API to check required margins before placing orders.
Rate Limits
| Endpoint | Rate Limit | Notes |
|---|---|---|
| Order placement | 10 requests/second | Sufficient for most strategies |
| Historical data | 3 requests/second | Can be slow for bulk backfilling |
| WebSocket | 3,000 instruments max | Subscribe/unsubscribe to manage |
| All other endpoints | 10 requests/second | Shared across all non-order endpoints |
Documentation Quality
Excellent. Kite Connect's documentation at kite.trade is well-organized, with code examples in Python, Java, Go, PHP, and Node.js. The official Python SDK (kiteconnect) is maintained by Zerodha and covers all API functionality. Community support is strong — Stack Overflow, GitHub issues, and the Zerodha developer forum are active.
Angel One SmartAPI
SmartAPI is Angel One's (formerly Angel Broking) developer platform. Its biggest advantage over Kite Connect: it is completely free. No monthly subscription, no historical data charges. For traders who want API access without the Rs 4,000/month burn of Kite Connect, SmartAPI is the obvious starting point.
Pricing
Free API access. Standard Angel One brokerage applies (Rs 20 per order for intraday/F&O, zero for equity delivery). No historical data charges. This makes SmartAPI the cheapest option for developers who are just starting with trading automation or who trade infrequently.
Key Features
- WebSocket streaming: Real-time data for up to 1,000 instruments. Latency similar to Kite Connect at 100-400ms.
- Order types: Market, limit, SL, SL-M, AMO (After Market Orders), GTT. No bracket or cover order support through the API — a notable limitation.
- Historical data: Free historical candle data (1-min to daily). Limited to 30 days of minute data and 2 years of daily data.
- SmartStream: WebSocket v2 with improved data compression and lower bandwidth usage.
- Portfolio APIs: Holdings, positions, order book, trade book.
Rate Limits
| Endpoint | Rate Limit | Notes |
|---|---|---|
| Order placement | 10 requests/second | Same as Kite Connect |
| Historical data | 1 request/second | Slower than Kite Connect — backfilling takes longer |
| WebSocket | 1,000 instruments max | Lower than Kite Connect's 3,000 |
| Authentication | TOTP-based (no manual intervention after setup) | Good for automated login |
Documentation Quality
Decent but inconsistent. The official docs at smartapi.angelone.in cover the basics but lack the depth and examples of Kite Connect. The Python SDK (smartapi-python) works but has occasional bugs that require workarounds. Community support is growing but smaller than Zerodha's ecosystem.
Upstox API v2
Upstox's API v2 (launched 2024) is a significant improvement over their previous API. It offers a middle ground between Kite Connect's polish and SmartAPI's free pricing, though it sits in an awkward position where it does not clearly win on either dimension.
Pricing
Free API access for basic features. Historical data is free for daily candles, with intraday data available at no extra cost. Standard Upstox brokerage: Rs 20 per intraday/F&O order, zero for delivery.
Key Features
- WebSocket streaming: Real-time data using Server-Sent Events (SSE) or WebSocket. Supports up to 2,000 instruments.
- Order types: Market, limit, SL, SL-M, AMO. GTT support was added in late 2025.
- Historical data: Free intraday and daily data. Up to 1 year of minute-level data.
- OAuth2 authentication: Standard OAuth2 flow, which is cleaner than Kite Connect's custom token system but requires a redirect URL setup.
Head-to-Head Comparison
| Feature | Kite Connect | SmartAPI | Upstox v2 |
|---|---|---|---|
| Monthly Cost | Rs 2,000 (+ Rs 2,000 for historical) | Free | Free |
| WebSocket Instruments | 3,000 | 1,000 | 2,000 |
| Historical Data Depth | 2 years (minute), full (daily) | 30 days (minute), 2 years (daily) | 1 year (minute), full (daily) |
| Bracket Orders | Yes | No | No |
| GTT via API | Yes | Yes | Yes (since 2025) |
| Documentation | Excellent | Good | Good |
| Python SDK Quality | Excellent (officially maintained) | Adequate | Good |
| Community Size | Largest in India | Medium, growing | Small |
| Uptime (2025 track record) | 99.7% | 99.3% | 99.1% |
| Best For | Production algo trading | Budget-conscious developers | Multi-broker setups |
Which API Should You Choose?
Choose Kite Connect if: You are running production trading strategies with real capital exceeding Rs 5 lakh, need bracket order support, require deep historical data for backtesting your systematic strategies, or want the largest community and best documentation. The Rs 4,000/month cost is trivial if your strategy generates consistent profits.
Choose SmartAPI if: You are learning API trading, building your first bot, trading with capital under Rs 2 lakh, or want to prototype strategies before committing to a paid API. The free access removes financial pressure during the learning phase. Upgrade to Kite Connect later if you outgrow SmartAPI's limitations.
Choose Upstox v2 if: You want free API access with more WebSocket capacity than SmartAPI (2,000 vs 1,000 instruments), or you are building a multi-broker system and need a second execution venue for redundancy.
The Multi-Broker Approach
Experienced algo traders in India increasingly use two brokers: Kite Connect as the primary execution venue and SmartAPI or Upstox as a backup. If Zerodha's API is down during a critical entry signal, the bot automatically routes the order through the backup broker. This redundancy costs nothing if you use SmartAPI (free) as backup and saves you from the frustrating experience of watching your perfect setup trigger while your API returns timeout errors.
Practical Tips for Indian Trading API Development
- Handle the login flow gracefully: All three APIs require daily re-authentication (SEBI regulation). Automate the login process — Kite Connect uses request tokens, SmartAPI uses TOTP, Upstox uses OAuth2. The most reliable approach: schedule a cron job at 9:00 AM IST to handle authentication before market opens at 9:15 AM.
- Build in retry logic: During high-volatility sessions (budget day, RBI policy, Nifty 500+ point moves), API response times spike. Implement exponential backoff with 3 retries on order placement failures.
- Log everything: Every API call, every response, every error. Store in a database (PostgreSQL on Supabase free tier works well). When something goes wrong — and it will — your logs are the only way to diagnose whether the issue was your code, the broker API, or exchange connectivity.
- Test on paper first: All three APIs support paper trading or sandbox modes. Never deploy a new strategy directly to production. Run it in parallel (paper + live) for at least 2 weeks before switching fully to live.
Common Pitfalls When Building on Indian Trading APIs
After 3+ years of building production trading systems on these APIs, here are the mistakes that cost me real money:
- Not handling split/bonus adjustments: Historical data from all three APIs does NOT automatically adjust for stock splits, bonuses, or rights issues. If your backtest shows a 50% overnight drop in a stock, it might be a 2:1 split, not a crash. Always check the NSE corporate actions calendar and adjust your data accordingly.
- Assuming order placement equals execution: An "order placed" response does not mean your order was filled. Always poll the order status or use WebSocket order updates to confirm execution before taking any further action in your code. Many beginners assume the order went through and start calculating P&L on phantom positions.
- Ignoring frozen instruments: NSE freezes trading in certain F&O instruments when open interest crosses a threshold. Your API will return an error if you try to place an order on a frozen contract. Build a pre-check that verifies the instrument status before order placement.
- Rate limit exhaustion during market opens: The 9:15-9:20 AM window sees the highest API traffic. If your bot makes multiple rapid-fire calls during this window, you will hit rate limits and miss entries. Batch your morning orders into a single API call burst at 9:14:50 AM, before the rush.
For international market access alongside Indian APIs, platforms like Exness provide MT5 API (MQL5) for forex and CFD automation. Many Bangalore-based tech traders run dual systems: NSE automation through Kite Connect during Indian market hours and forex automation through MT5 during the evening London-New York session.