Urgent: Unable to connect to market depth websocket

Since today, the WebSocket connection has been returning the following error:

Oct 15 09:27:17 localhost python[11715]: 2026-10-15 09:27:17 - ERROR - MarketFeed websocket error: server rejected WebSocket connection: HTTP 429

The WebSocket URL is:

uri = f"wss://api-feed.dhan.co?version=2&token={token}&clientId={client_id}&authType=2"

I have also tried connecting using the DhanHQ library, but I am getting the same HTTP 429 error there as well.

Could you please check whether there has been any recent change or restriction on the Dhan WebSocket API that could be causing this?

Hello @Vishal_Singh ,

We want to inform you that, there have been made no changes from our end with respect to the Live Market Feed Websocket.

Please make sure to not breach the rate limits (more than 5 active connections or more than 10 connection request within a second) and use the active access token to connect to live market feed.

As you are using python to connect to live market feed, you may refer to the sample codes shared over Github. Incase you continue to face the same rejections then share an email with us at apihelp@dhan.co