Introduction
WebSocket proxying lets Nginx forward WebSocket connections from clients to backend servers. This solves the problem of handling real-time communication through a reverse proxy.
When you want to serve a chat app through Nginx that uses WebSocket for live messages.
When your backend server supports WebSocket but clients connect through Nginx for security.
When you need to load balance WebSocket connections across multiple backend servers.
When you want to add SSL termination at Nginx for WebSocket traffic.
When you want to keep WebSocket connections alive and stable through a proxy.