hello i am facing a problm with websocket connections when i'm running my deployed app. on a local host it works just fine but on vercel the websocket is not connected
Hi @trishalamjain,
Due to the nature of Vercel’s serveless infrastructure, WebSocket connections aren’t supported.
While Vercel Functions technically support streaming responses, they have a maximum execution limit and will time out after a certain amount of time, so keeping a connection (via WS) alive isn’t possible in this case.
Alternatively, you can also fetch realtime data on-demand, using packages like SWR.
You can learn more in this troubleshooting Guide here.
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.