n8n Webhooks and the HTTP Request Node: Connect Any App to n8n
How n8n webhooks and the HTTP Request node work: test vs production URLs, responding to webhooks, calling any API, authentication and securing your endpoints.

n8n ships with hundreds of integrations, but the two nodes that make it truly limitless are generic ones. The Webhook node lets any app send data to n8n. The HTTP Request node lets n8n send data to any app with an API. Learn these two and "is there an n8n node for X?" stops being a question that matters.
The Webhook node: let any app trigger n8n
A webhook is just a URL. When something happens in another app (a form is submitted, a payment succeeds, a message arrives), that app sends an HTTP request to the URL, and n8n starts your workflow with the request's data.
- Add a Webhook node as the trigger and choose the HTTP method the other app will use (usually POST).
- Copy the Test URL and paste it into the other app's webhook settings.
- Click Listen for test event in n8n, then trigger the event in the other app. The data appears in the Webhook node's output.
- Build the rest of the workflow using that sample data.
- When it works, activate (publish) the workflow and switch the other app to the Production URL.
Test URL vs Production URL
The Test URL only works while you are listening in the editor, and shows each request on the canvas. The Production URL only works when the workflow is active, and requests appear in the Executions list instead. Mixing them up is the number one reason "my webhook does nothing".
By default n8n replies as soon as the webhook is received. If the caller needs an answer (a form waiting for a result, a chatbot waiting for a reply), set the Webhook node to respond using a Respond to Webhook node and place that node where your answer is ready.
Recommended tutorials from the library
The HTTP Request node: call any API
The HTTP Request node is how n8n talks to services that do not have a dedicated node, or does things the dedicated node does not support. You need four things from the API documentation: the URL (endpoint), the method (GET to read, POST to create, PATCH/PUT to update, DELETE), the authentication method, and the body or query parameters.
The fastest way to set it up: most API docs show a cURL example. In the HTTP Request node, click Import cURL, paste it, and n8n fills in the method, URL, headers and body for you. Then replace the hard-coded values with expressions like {{ $json.email }}.
- Pagination: for APIs that return results page by page, use the node's built-in pagination options instead of building a loop.
- Batching and rate limits: if an API limits requests per second, enable batching to space requests out.
- As an agent tool: the HTTP Request Tool lets an AI agent call an API itself. Describe clearly what it does, so the agent uses it at the right moment.
Recommended tutorials from the library
Authentication and keeping keys safe
Never paste an API key straight into a header field. Create a credential instead (Header Auth, Bearer, Basic Auth, OAuth2, or a predefined credential type for a known service). Credentials are encrypted, reusable across workflows, and not exposed when you share or export a workflow.
Recommended tutorials from the library
Securing your webhooks
A production webhook URL is public: anyone who finds it can send data to your workflow. For anything that matters:
- Turn on authentication in the Webhook node (Header Auth or Basic Auth) and have the sender include the secret.
- Verify signatures where the sender supports them (Stripe, GitHub and many others sign their webhooks).
- Validate the payload with an IF node before doing anything expensive, and reject anything unexpected.
- Do not leak data in responses: return only what the caller needs.
Recommended tutorials from the library
Where to go next
With webhooks and HTTP requests you can connect anything, which is the foundation for every serious n8n project. Next, learn to master the core nodes that shape data between them, then move on to AI agents. If you are self-hosting and your webhook URLs show "localhost", see the configuration section of our self-hosting guide.
Recommended tutorials from the library
Frequently asked questions
What is the difference between the test and production webhook URL in n8n?
The test URL works only while you click "Listen for test event" in the editor and shows data on the canvas. The production URL works only when the workflow is active and logs runs in the Executions list. Use the test URL while building, then switch to production.
Why is my n8n webhook not working?
The most common causes are using the test URL when the workflow is not listening, using the production URL when the workflow is not active, a wrong HTTP method, or a self-hosted instance whose WEBHOOK_URL still points to localhost.
How do I call an API in n8n?
Use the HTTP Request node. Set the method and URL from the API documentation, add authentication as a credential, and fill in parameters or a JSON body. The quickest way is to paste the documentation's cURL example using the node's Import cURL option.
How do I return data from an n8n webhook?
Set the Webhook node's Respond option to "Using Respond to Webhook node", then add a Respond to Webhook node at the point in your workflow where the answer is ready. You can return JSON, text, a redirect or a file.






