Zerodha API IP Not Whitelisted — Fix Kite Connect Origin Errors

Zerodha API IP Not Whitelisted — Fix Kite Connect Origin Errors

Zerodha Kite says IP not whitelisted or TokenException after a working session? Check exit IP, Kite whitelist field, and HTTP proxy 443 on REST plus KiteTicker.

What Zerodha is actually checking

Kite Connect compares the public IPv4 of each HTTPS call with the address in developers.kite.trade → My Apps → IP Whitelist. If you saved yesterday’s home broadband address, or the bot skipped the proxy for one thread, you get IP-not-whitelisted or a TokenException that looks like an auth bug.

Confirm the exit IP Kite sees

Run this from the same process that calls kite.place_order — not from a different terminal without the proxy:

That string must match the Kite whitelist field exactly. Do not TLS-handshake port 443 — it is HTTP CONNECT, not the website.

Kite-specific failure modes

Fix that stays overnight

Allocate a dedicated Algo-IP IPv4 (₹200/month) after KYC. Paste it once into the Kite app. Set HTTPS_PROXY for the whole process before you import kiteconnect. Walk through the dedicated setup page at /brokers/zerodha and the older whitelist guide if you need screenshots of the portal.