At a glance
- Set the public URL yourselfSet
N8N_WEBHOOK_URLto your public address, for examplehttps://n8n.example.com/. - Pass on the original requestOn the last proxy before n8n, set the
X-Forwarded-For,X-Forwarded-HostandX-Forwarded-Protoheaders. - Check it worksRestart n8n and open a Webhook node.
Set the public URL yourself
- Set
N8N_WEBHOOK_URLto your public address, for examplehttps:/./ n8n. example. com/ N8N_WEBHOOK_URLreplacesWEBHOOK_URL, which is deprecated from n8n 2.35.0 and logs a warning.- Set
N8N_PROXY_HOPSto1.
Pass on the original request
- On the last proxy before n8n, set the
X-Forwarded-For,X-Forwarded-HostandX-Forwarded-Protoheaders. - If you also run n8n's instance-level MCP server behind the same proxy, forward its MCP request headers too.
- Set the public URL yourself
- Pass on the original request
- Check it works
Check it works
- Restart n8n and open a Webhook node. The production URL should start with your public HTTPS address.
- Activate a workflow with a trigger that registers a webhook, such as Telegram, and confirm events arrive.
Updated 2026-11-09. General guidance, not advice for your situation; we scope each project in writing before any work starts.
What the sources say
| What the source says | Source |
|---|---|
| “That's because n8n runs internally on port 5678 but the reverse proxy exposes it to the web on port 443.” | n8n, n8n docs: Configure webhook URLs with reverse proxy |
| “When running n8n behind a reverse proxy, you must configure the WEBHOOK_URL environment variable with the public URL where your n8n instance is running.” | n8n, n8n docs: Telegram Trigger common issues |
N8N_WEBHOOK_URL is available from n8n 2.30.0; earlier versions use WEBHOOK_URL (docs.n8n.io, as of 2026-11-17).
Sources
- n8n docs: Configure webhook URLs with reverse proxy (checked 2026-11-17)
- n8n docs: Telegram Trigger common issues (checked 2026-11-17)
Questions people ask first
Why does the editor still show localhost?
The webhook URL variable is not set, or n8n was not restarted after setting it.
Do I need HTTPS?
Some services require it. Telegram, for example, rejects a webhook address that is not HTTPS.
Which port does n8n listen on?
5678 inside. The reverse proxy usually exposes it on 443, which is why n8n cannot work out the public URL on its own.
Tell us what you need built.
Tell us the process and the tools involved. We reply with questions or a written scope.
hello@pushbuild.com