Webhook not responding in both test and production mode
I created a simple webhook and I’m trying to test it, but when I click “Listen for test event” and open the test URL in my browser, nothing happens - the webhook keeps waiting indefinitely.
I tried the following:
Restarted the Docker container where n8n is running on my PC
Activated the workflow and tried hitting the production URL (without -test)
Tried different browsers
None of these worked. The webhook never receives the request.
Running on: Docker (local)
OS: Linux
Has anyone experienced this issue? I found GitHub Issue #15586 which describes the same problem, but it was closed without a fix.
Any help would be appreciated.
Any response doing a GET request with another HTTP client? (insomnia, postman etc)
Show your docker run command or docker-compose or running container details, and which url you use to access the n8n instance
Also possibly related to your WEBHOOK_URL and WEBHOOK_TEST_URL env variables. Did you set them? (also possible relevant env vars, N8N_HOST, N8N_DOMAIN if set etc, N8N_PORT if not set also)
curl -v http://localhost:5678/webhook-test/marcar-atendido
Returns 404: “The requested webhook is not registered” (even while “Listen for test event” is active in UI)
curl -v http://localhost:5678/webhook/marcar-atendido
Hangs indefinitely (no response, had to Ctrl+C). The workflow IS activated.
Logs show: Node 'Webhook: Marcar Atendido' hasn't been executed
docker-compose.yml:
services:
n8n:
image: n8nio/n8n:latest
ports:
- "5678:5678"
volumes:
- n8n_data:/home/node/.n8n
restart: unless-stopped
environment:
- N8N_HOST=0.0.0.0
- N8N_PROTOCOL=http
- WEBHOOK_URL=http://localhost:5678/
volumes:
n8n_data:
Environment variables inside container:
N8N_HOST=0.0.0.0
N8N_PROTOCOL=http
WEBHOOK_URL=http://localhost:5678/
N8N_RELEASE_TYPE=stable
Not set: WEBHOOK_TEST_URL, N8N_DOMAIN, N8N_PORT
URL to access n8n: http://localhost:5678 (works fine, editor loads normally)
n8n version: 2.3.5
I think docker compose file is ignoring your .env file, you need to also add this to your n8n service
env_file:
- .env
Another thing, I would try to use N8N_HOST as localhost or 127.0.0.1 too.
Variables seem ok, but maybe the missing variables are breaking your app. Try to add whatever variables are missing here, and ignore the subdomain ones. Also you can probably ignore the DOMAIN_NAME variable.
# your domain with subdomain or localhost if local
N8N_HOST=n8n.hhh.br
# your full app url, or http://localhost:port/ if accessing locally
N8N_EDITOR_BASE_URL=https://n8n.hhh.br/
# The top level domain to serve from, this should be the same as the top level for the subdomain you created above
# leave empty or localhost (?)
DOMAIN_NAME=hhh.br
# The subdomain to serve from - leave empty if localhost (*?)
SUBDOMAIN=n8n
# http://localhost:port/ if running locally
WEBHOOK_URL=https://n8n.hhh.br/
N8N_ENDPOINT_WEBHOOK=webhook
N8N_ENDPOINT_WEBHOOK_TEST=webhook-test
#WEBHOOK_TUNNEL_URL=https://hhh.br/ # not needed
# Number of reverse-proxies n8n is running behind.
N8N_PROXY_HOPS=1
# set to 0 if you are not using a reverse proxy
N8N_PORT=5678
N8N_PROTOCOL=https
# http if not using ssl
NODE_ENV=production
btw if you want to expose your local instance to the internet, I would not set 0.0.0.0 in n8n host, instead set it to whatever url your outside clients will access your app from (like your ip: http://ip:port/ ).
Your docker compose already exposes your container port publicly when you configure the ports like that 5678:5678. It is the same as setting 0.0.0.0:5678:5678 .
It would only be limited to local access if you configured it like this: “127.0.0.1:5678:5678”
To sum it up, this indicates to me that your n8n instance is expecting another URL to be called, instead of what you are calling. So the webhook url, n8n host, or env vars are preventing you from calling it.
… I would guess your issue is probably the wrong n8n host env. it is expecting you to call like 0.0.0.0:port/webhook… So start with configuring the n8n host variable to be localhost or 127.0.0.1 or your ip + matching webhook url env var with that… with similar sytnax to my examples.
Not set: WEBHOOK_TEST_URL, N8N_DOMAIN, N8N_PORT
also possibly an issue, you must set test url and port vars. domain not necessary
Hey! Thanks a lot for your help!
I changed N8N_HOST from 0.0.0.0 to localhost as you suggested, but that wasn’t the actual fix.
The real problem was embarrassingly simple: the Webhook node was outdated (version 2 instead of 2.1). I updated it and everything works now.
Why did I have an old node? I’ve been using Claude Code with n8n-mcp and n8n-skills to generate workflows via AI, and it created the webhook with an older node version. Classic “AI did it” excuse ![]()
On the bright side, I learned something useful from our conversation: 0.0.0.0 means “listen on all network interfaces” (useful for Docker to accept connections), while localhost/127.0.0.1 is a specific address that tells the app “this is how clients will call me” — and those two need to match for routing to work correctly.
Rookie mistake, won’t happen again… until it does ![]()
Thanks again!
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

