Title: Localhost error (http://localhost:5678/) when using e.g. Slack or Gmail “Send and wait for response” nodes
n8n Version: 1.12.4
Instance Type: Self-hosted (Docker with Hostinger)
Problem:
Gmail “Send Message and Wait for Response” node generates approval links pointing to http://localhost:5678 instead of my configured domain, causing “connection refused” errors when recipients click the links.
Environment Variables in docker-compose.yml:
yaml
- N8N_HOST=${SUBDOMAIN}.${DOMAIN_NAME}
- N8N_PROTOCOL=https
- WEBHOOK_URL=https://${SUBDOMAIN}.${DOMAIN_NAME}/
- N8N_EDITOR_BASE_URL=https://${SUBDOMAIN}.${DOMAIN_NAME}/
- N8N_PROXY_HOPS=1
```
Verified inside container via:
bash
docker exec <container_name> printenv | grep -E "N8N_HOST|WEBHOOK_URL|N8N_PROTOCOL|EDITOR|PROXY"
Output confirms variables resolve correctly to subdomain.mydomain.com
What works:
-
Regular Webhook nodes show correct URL (both Test and Production)
-
Accessing n8n via
subdomain.mydomain.com worksfine
What doesn’t work:
- e.g. Gmail “Send and Wait for Response” approval links still use
localhost:5678
Setup:
-
Docker Compose
-
PostgreSQL database
-
Redis queue mode
Already tried:
-
Cleared browser cache
-
Created new webhook nodes
-
Restarted containers multiple times
-
Restarted VPS
-
Added N8N_PROXY_HOPS=1
Any help appreciated!!! Unfortunately this issue has not been solved also it was mentioned couple of times in the forum here in older threads.

