Static IP for Dhan HQ API
Dhan HQ checks the source IP on order APIs. You can register more than one address, but a rotating home IP still burns slots. One dedicated IPv4 is the stable option.
Dhan API facts
- API: Dhan HQ
- Portal: web.dhan.co
- Whitelist: API profile → Static IP
- IPv4: yes
- IPv6: confirm in portal
- Max IPs: Dhan allows multiple whitelist slots per app (commonly up to 5 — confirm in portal)
- Protocols: HTTP proxy, REST, WebSocket
- Last verified: 2026-09-22
How to whitelist a static IP
- Allocate Algo-IP IPv4 (IPv6 only if Dhan’s field accepts IPv6).
- In web.dhan.co open API profile → Static IP and paste the address.
- Set HTTP proxy host + port 443 on REST and WebSocket clients.
- Verify egress with api.ipify.org before the first live order.
Python / proxy hint
Use requests Session.proxies or httpx proxies pointing at HOST:443.
Common errors
Dhan 401 / 403 IP error
Order did not exit the whitelisted IP. Confirm proxy on both REST and market-data sockets.
Related guide: dhan-hq-api-static-ip-whitelisting-guide. Also see dedicated IPv4, trading proxy and all brokers.
Other broker setups
- Static IP for Zerodha Kite API
- Angel One SmartAPI Static IP
- Fyers API Static IP
- Upstox API Static IP
- Static IP for Groww API
- Static IP for 5Paisa API
- Static IP for Alice Blue ANT API
- Static IP for Shoonya (Finvasia) API
- Static IP for Kotak Neo API
- Static IP for mStock (Mirae) API
- Static IP for Goodwill API
- Static IP for ICICI Direct Breeze API
- Static IP for HDFC Sky API