Skip to content

Nginx Configuration for Websocket Applications

💡 Using Nginx as a reverse proxy for your Node.js websocket app?

👉🏼 Add the following config lines to Nginx to make it all work smoothly.

To have Nginx work smoothly with Websocket apps, use proxy_http_version 1.1 and set the following headers with proxy_set_header: Upgrade $http_upgrade, Connection $http_connection, Host $host.
A preview of the VPS Security Cheatsheet.

Download the VPS Security Cheatsheet

No spam! 🙅🏻‍♀️ Unsubscribe at any time.