Next.js Discord

Discord Forum

Socket not received in prod

Unanswered
Masai Lion posted this in #help-forum
Open in Discord
Masai LionOP
Hey, in devmode, the frontend of my app receives the websocket without any problem, but in prod mode, it doesnt. Do you know why ? The websocket is sent without any problem. The websocket connection is established without any problem.

7 Replies

@Masai Lion I dont use any Vercel serverless function
Next.js is a serverless framework, it does not support websockets
You can connect to a websocket microservice, though, if needed
@Marchy Next.js is a serverless framework, it does not support websockets
Masai LionOP
But the connection/disconnection to a websocket works
@Masai Lion But the connection/disconnection to a websocket works
That doesn't mean it's supported.
@Marchy That doesn't mean it's supported.
Masai LionOP
Alright I've implemented Pusher Channels, it works now 👌