ACLClouds
ACLClouds

How do I expose an n8n webhook over HTTPS?

Configure DNS, the reverse proxy and WEBHOOK_URL, then test the production URL.

External integrations typically require HTTPS. Port 5678 should remain listening locally behind Caddy or Nginx.

Step-by-step procedure

  1. Create the DNS record

    Add an A record for n8n.example.com pointing to the VPS IPv4 address.

  2. Configure n8n

    Set N8N_HOST, N8N_PROTOCOL=https and WEBHOOK_URL in Compose, then recreate the container.

  3. Install Caddy

    Make Caddy listen on ports 80 and 443 and reverse-proxy to 127.0.0.1:5678.

  4. Open the firewall ports

    Allow HTTP and HTTPS. Keep 5678 closed to the public network.

  5. Test the production URL

    Activate a Webhook node, copy the production URL, then call it with curl or the source application.