Set up your WhatsApp Business API for free. No credit card needed.Set up your WhatsApp API for free.Get started

· Guide

How to connect your WhatsApp Business number to n8n

Connect your WhatsApp Business number to n8n with Hello’s direct webhook: generate the verify token, build the workflow, reply through the API and test it.

Updated

To connect your WhatsApp Business number to n8n, turn on Hello’s direct webhook for that number, then build a short workflow in n8n. A direct webhook is a setting that sends one number’s incoming messages straight to an address you choose, here your n8n workflow. A workflow is a chain of steps, which n8n calls nodes. Yours receives the message and replies through Hello’s API, using an HTTP Request node. Because Hello supports coexistence, the number also stays active in the WhatsApp Business app on your phone.

You do not need a community node, a Meta developer app or an OAuth sign-in. No earlier experience with webhooks is needed: each step names the screen, the field and the value to enter, in the order you will meet them. By the end, a message sent to your business number starts an n8n execution (one run of the workflow), and the reply arrives on the customer’s phone. Allow about half an hour for a first setup.

How the pieces fit together

A webhook is a web address that receives a notification from another system the moment something happens. Here, Meta calls your n8n webhook each time a customer writes to your number. Your reply travels the other way, through Hello.

Customer ──► WhatsApp ──► Meta ──► your n8n webhook (GET: check, POST: messages)
│
your logic
│
▼
Hello API POST /v1/<phone-number-id>/messages ──► WhatsApp ──► Customer
  • Incoming: Meta sends every event for your number to one n8n address. Before it sends anything, Meta checks once that the address belongs to you. The verify token in this guide is what answers that check.
  • Outgoing: n8n replies by calling Hello’s send endpoint with your Hello API key. The request has the same shape as a message sent through Meta’s WhatsApp Cloud API.

What changes in Hello when you turn this on

Read this section before you begin. A direct webhook moves the events of one phone number from Hello to a server of your own, here n8n.

  • Hello stops receiving that number’s incoming messages and delivery statuses. They go only to n8n, so Hello’s delivery figures for that number stop updating. Your workflow becomes responsible for handling them.
  • Sending still works through Hello and still counts against your plan. WhatsApp still enforces the 24-hour window.
  • Template and account updates still come to Hello.
  • There is no fallback. If n8n is down, Meta retries for a while but never sends the events to Hello instead.
  • Other numbers are not affected.
  • It is reversible. Removing the direct webhook sends the number’s events to Hello again immediately.

If you are only experimenting, use a number that is not yet in daily use. The full rules are in the direct webhook documentation.

What you need

You need Where to get it
A WhatsApp Business number connected to Hello WhatsApp Accounts in Hello; see coexistence
A plan that includes direct webhook If yours does not, the Webhooks page tells you so
A Hello API key (starts with hello_live_) Integrations → Create API Key. You can reveal the key again later from the keys list
Hello’s Server URL The Integrations page, labelled Server URL. Copy it rather than typing it
The number’s phone number ID WhatsApp Accounts, on the number’s card, with a copy button
n8n with a public HTTPS address n8n Cloud, or a self-hosted instance that is reachable from the internet

Keep a plain text note open. You will paste three values into it: the webhook address, the verify token and your API key.

Step 1: choose your n8n webhook address

  1. In n8n, create a new workflow and add a Webhook node.
  2. Set HTTP Method to GET, Path to whatsapp-webhook, and Respond to Using ‘Respond to Webhook’ Node.
  3. Open the Production URL tab on the node and copy the address. It looks like https://your-n8n.example.com/webhook/whatsapp-webhook.

Use the Production URL, not the Test URL. The test address works only while you are watching the editor, so Meta cannot use it. The production address works once the workflow is published (step 7).

Step 2: generate the secret path and verify token in Hello

Now open Hello’s form and fill it in, but do not save it yet. It creates two values that you must also enter in n8n before you save.

  1. In Hello, open Webhooks and choose Add webhook.

  2. Under Choose a number, pick the number. Only active numbers without a webhook are offered.

  3. Paste the address from step 1 into Your HTTPS endpoint.

  4. Choose Generate secret path. Hello adds a random code to the end of your address:

    https://your-n8n.example.com/webhook/whatsapp-webhook/9f2c4e1a7b3d5e8f0a1b2c3d4e5f6a7b
  5. Next to Verify token, choose Generate. Hello fills in a random 32-character token.

  6. Copy the full address and the verify token into your note. Keep the form open.

These two values do different jobs:

  • The secret path helps you tell genuine requests from guesses. Meta signs every delivery with a secret that belongs to Hello and cannot be shared, so your workflow cannot check the signature. A long random code in the address takes its place, because only you and Meta know it. Keep it in the path, not in a query string, which other systems often log.
  • The verify token lets your workflow pass Meta’s one-time check. When you save, Meta calls your address with this token, and your workflow replies only if the token is the right one.

Copy the verify token now. Hello stores it encrypted and never shows it again. If you lose it, you can generate a new one later under Manage → Change URL or token and update n8n to match.

Step 3: answer Meta’s check (the GET branch)

Meta uses two kinds of request: GET for the one-time check and POST to deliver messages. So the workflow needs two Webhook nodes that share one path. Start with the check. If you would rather skip steps 3 to 6 and begin with a finished workflow, go to import the ready-made workflow.

  1. In the Webhook node from step 1, change Path to whatsapp-webhook/ followed by your secret code, for example whatsapp-webhook/9f2c4e1a7b3d5e8f0a1b2c3d4e5f6a7b. The Production URL shown on the node must now match the address in Hello’s form, character for character.
  2. Add an If node with two conditions that must both be true (AND):
    • {{ $json.query['hub.mode'] }} is equal to subscribe
    • {{ $json.query['hub.verify_token'] }} is equal to your verify token
  3. From the true output, add a Respond to Webhook node. Set Respond With to Text, Response Body to {{ $json.query['hub.challenge'] }}, and under Options set Response Code to 200.
  4. From the false output, add another Respond to Webhook node with Response Body Forbidden and Response Code 403.

The challenge must come back as plain text, exactly as Meta sent it.

Step 4: receive the messages (the POST branch)

  1. Add a second Webhook node. Set HTTP Method to POST, use the same path as in step 3, and leave Respond on Immediately. Meta expects a fast 200 reply, and it retries when it does not get one.

  2. Add an Edit Fields node set to JSON mode, with this expression, to keep only the part of Meta’s data that you need:

    {{ JSON.stringify($json.body?.entry?.[0]?.changes?.[0]?.value ?? {}) }}
  3. Add a Filter node that keeps an item only when {{ $json.messages?.[0]?.from }} exists. The same address also receives delivery statuses, and this drops them.

After the Filter, you can read the message with these expressions:

What Expression
Sender’s number {{ $json.messages[0].from }}
Your phone number ID {{ $json.metadata.phone_number_id }}
Message type {{ $json.messages[0].type }}
Text of the message {{ $json.messages[0].text.body }}
Message ID {{ $json.messages[0].id }}
Sender’s WhatsApp profile name {{ $json.contacts[0].profile.name }}

type tells you what arrived: text, image, document, location, button for a template button tap, interactive for a list or reply button, and so on. Media messages carry an ID rather than the file itself.

Step 5: add your own logic

This step is yours to design: an AI agent, a database lookup, a routing rule or a call to your booking system. Whatever you build, it must end with three values for the next step:

  • phoneNumberId, the number the customer wrote to
  • to, the customer’s number
  • reply, the text to send

For a first test, add an Edit Fields node that sets phoneNumberId to {{ $json.metadata.phone_number_id }}, to to {{ $json.messages[0].from }} and reply to You said: {{ $json.messages[0].text.body }}. The sender’s number arrives as digits without a leading +, which Hello accepts as a WhatsApp ID.

Step 6: create the credential and send the reply

First, save your API key as a credential, so that the key never sits inside the workflow itself.

  1. Add an HTTP Request node. Set Authentication to Generic Credential Type, then choose Custom Auth.

  2. Create a new credential from this template, and save it as Hello API Key:

    { "headers": { "Authorization": "Bearer hello_live_YOUR_API_KEY" } }

Then set up the request in the same node:

  • Method: POST
  • URL: https://<your Hello Server URL>/v1/{{ $json.phoneNumberId }}/messages
  • Send Body: on, Body Content Type: JSON, Specify Body: Using JSON
{{ JSON.stringify({
messaging_product: 'whatsapp',
to: $json.to,
type: 'text',
text: { body: $json.reply }
}) }}

Unless the API key is set to synchronous, Hello answers at once with 202, "message_status": "queued" and a hello_id, and sends the message in the background. Two optional extras are worth adding:

  • Query parameter sync = true makes Hello wait until WhatsApp has accepted the message, then return WhatsApp’s message ID (wamid).
  • Header Idempotency-Key, set to the incoming message’s ID {{ $json.messages[0].id }}, lets Hello recognise a repeated request and return the original message instead of sending a second reply. The template includes it.

Every other message type (image, document, interactive buttons, template, reaction) uses the same endpoint. Only type and its matching object change; the send message reference lists them all.

Step 7: publish the workflow

Click Publish at the top right. Older versions of n8n call this Activate. Check that the node’s Production URL matches the address in Hello’s form exactly. A published workflow listens on /webhook/…, while a workflow you are testing in the editor listens on /webhook-test/….

Step 8: turn on the direct webhook in Hello

Go back to the form from step 2.

  1. Check that Your HTTPS endpoint and Verify token still hold the values from your note.
  2. Tick I understand that this number’s messages and statuses will no longer be tracked here.
  3. Choose Turn on direct webhook.

Hello asks Meta to use your address, and Meta checks it at once by calling your GET branch. If the check passes, the status changes to Active. If it fails, nothing changes in Hello, and the error shows what Meta saw, including the HTTP status that n8n returned. A 404 usually means a wrong path or an unpublished workflow, and a 403 means the token does not match. The common problems table covers more.

Step 9: test it

  1. From a different phone, send a WhatsApp message to your business number. A number cannot message itself.
  2. In n8n, open Executions. You should see the POST branch run, and the Hello call return 200 or 202.
  3. The reply should arrive on the phone, usually within a few seconds.

You will also see executions for delivery statuses. The Filter stops them, so those runs end early, and that is expected.

Import the ready-made workflow

If you prefer to start from a finished workflow, use this one. It contains every node from steps 3 to 6 and echoes the customer’s text back, so you can test before you add your own logic. It has placeholders instead of secrets, and no credential.

{
"name": "Hello WhatsApp API - n8n template",
"nodes": [
{
"parameters": {
"path": "whatsapp-webhook/REPLACE_WITH_YOUR_SECRET_PATH",
"responseMode": "responseNode",
"options": {}
},
"name": "Meta Verification (GET)",
"type": "n8n-nodes-base.webhook",
"typeVersion": 2.2,
"position": [0, 0]
},
{
"parameters": {
"conditions": {
"options": { "caseSensitive": true, "leftValue": "", "typeValidation": "strict", "version": 2 },
"conditions": [
{
"id": "mode",
"leftValue": "={{ $json.query['hub.mode'] }}",
"rightValue": "subscribe",
"operator": { "type": "string", "operation": "equals" }
},
{
"id": "token",
"leftValue": "={{ $json.query['hub.verify_token'] }}",
"rightValue": "REPLACE_WITH_YOUR_VERIFY_TOKEN",
"operator": { "type": "string", "operation": "equals" }
}
],
"combinator": "and"
},
"options": {}
},
"name": "Is Verify Token Valid",
"type": "n8n-nodes-base.if",
"typeVersion": 2.2,
"position": [220, 0]
},
{
"parameters": {
"respondWith": "text",
"responseBody": "={{ $json.query['hub.challenge'] }}",
"options": { "responseCode": 200 }
},
"name": "Return Challenge",
"type": "n8n-nodes-base.respondToWebhook",
"typeVersion": 1.5,
"position": [440, -100]
},
{
"parameters": {
"respondWith": "text",
"responseBody": "Forbidden",
"options": { "responseCode": 403 }
},
"name": "Reject Verification",
"type": "n8n-nodes-base.respondToWebhook",
"typeVersion": 1.5,
"position": [440, 100]
},
{
"parameters": {
"httpMethod": "POST",
"path": "whatsapp-webhook/REPLACE_WITH_YOUR_SECRET_PATH",
"options": {}
},
"name": "Incoming WhatsApp Event (POST)",
"type": "n8n-nodes-base.webhook",
"typeVersion": 2.2,
"position": [0, 300]
},
{
"parameters": {
"mode": "raw",
"jsonOutput": "={{ JSON.stringify($json.body?.entry?.[0]?.changes?.[0]?.value ?? {}) }}",
"options": {}
},
"name": "Extract Message Payload",
"type": "n8n-nodes-base.set",
"typeVersion": 3.4,
"position": [220, 300]
},
{
"parameters": {
"conditions": {
"options": { "caseSensitive": true, "leftValue": "", "typeValidation": "loose", "version": 2 },
"conditions": [
{
"id": "has-sender",
"leftValue": "={{ $json.messages?.[0]?.from }}",
"rightValue": "",
"operator": { "type": "string", "operation": "exists", "singleValue": true }
}
],
"combinator": "and"
},
"options": {}
},
"name": "Only Incoming Messages",
"type": "n8n-nodes-base.filter",
"typeVersion": 2.2,
"position": [440, 300]
},
{
"parameters": {
"assignments": {
"assignments": [
{ "id": "base-url", "name": "helloBaseUrl", "value": "https://REPLACE-WITH-YOUR-HELLO-SERVER-URL", "type": "string" },
{ "id": "phone-id", "name": "phoneNumberId", "value": "={{ $json.metadata.phone_number_id }}", "type": "string" },
{ "id": "to", "name": "to", "value": "={{ $json.messages[0].from }}", "type": "string" },
{ "id": "msg-id", "name": "incomingMessageId", "value": "={{ $json.messages[0].id }}", "type": "string" },
{ "id": "reply", "name": "reply", "value": "=You said: {{ $json.messages[0].text?.body ?? '(a message that is not text)' }}", "type": "string" }
]
},
"options": {}
},
"name": "Your Logic - Build Reply",
"type": "n8n-nodes-base.set",
"typeVersion": 3.4,
"position": [660, 300]
},
{
"parameters": {
"method": "POST",
"url": "={{ $json.helloBaseUrl.replace(/\\/$/, '') }}/v1/{{ $json.phoneNumberId }}/messages",
"authentication": "genericCredentialType",
"genericAuthType": "httpCustomAuth",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{ "name": "Idempotency-Key", "value": "={{ $json.incomingMessageId }}" }
]
},
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={{ JSON.stringify({ messaging_product: 'whatsapp', to: $json.to, type: 'text', text: { body: $json.reply } }) }}",
"options": {}
},
"name": "Send via Hello API",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [880, 300]
}
],
"connections": {
"Meta Verification (GET)": { "main": [[{ "node": "Is Verify Token Valid", "type": "main", "index": 0 }]] },
"Is Verify Token Valid": {
"main": [
[{ "node": "Return Challenge", "type": "main", "index": 0 }],
[{ "node": "Reject Verification", "type": "main", "index": 0 }]
]
},
"Incoming WhatsApp Event (POST)": { "main": [[{ "node": "Extract Message Payload", "type": "main", "index": 0 }]] },
"Extract Message Payload": { "main": [[{ "node": "Only Incoming Messages", "type": "main", "index": 0 }]] },
"Only Incoming Messages": { "main": [[{ "node": "Your Logic - Build Reply", "type": "main", "index": 0 }]] },
"Your Logic - Build Reply": { "main": [[{ "node": "Send via Hello API", "type": "main", "index": 0 }]] }
},
"settings": { "executionOrder": "v1" }
}

After importing, change four things:

Node Change
Meta Verification (GET) and Incoming WhatsApp Event (POST) Replace REPLACE_WITH_YOUR_SECRET_PATH with the code from step 2, in both nodes. The two paths must be identical
Is Verify Token Valid Replace REPLACE_WITH_YOUR_VERIFY_TOKEN with the token from step 2
Your Logic - Build Reply Replace https://REPLACE-WITH-YOUR-HELLO-SERVER-URL with the Server URL from Hello’s Integrations page, and replace the reply value with your own logic
Send via Hello API Create the Hello API Key credential from step 6 and select it

Then continue from step 7. n8n gives each Webhook node a new ID on import, so the template does not clash with your other workflows. The path, however, must be unique on an n8n instance.

Import and export workflows in n8n

n8n describes a workflow as JSON text, so moving it between n8n instances, or sharing it, takes only a few clicks.

Import

  • Paste (quickest): create an empty workflow, copy the JSON, click the canvas and press Ctrl + V (Cmd + V on a Mac). All the nodes and connections appear. Save.
  • From a file: save the JSON as hello-whatsapp-template.json. In a new workflow, open the ⋯ menu at the top right and choose Import from File.
  • From a URL: if the JSON is hosted somewhere public, such as a raw GitHub file, choose ⋯ → Import from URL.

Export

  • A whole workflow: open it, then choose ⋯ → Download. You get a .json file.
  • A few nodes: select them on the canvas and press Ctrl + C. The clipboard now holds valid workflow JSON that you can paste anywhere.

Check an export before you share it. Look for:

  • Credential names and IDs under "credentials" on each node. The IDs are not sensitive, but the names might be.
  • Secrets typed into node settings, such as your verify token in the If node, or an API key pasted into a header.
  • Your secret path, in the two Webhook nodes. Anyone who has it can post to your webhook.
  • Internal addresses, such as a staging Server URL.

When n8n starts a conversation

A reply to a customer who has just written to you can be free-form text, because their message opens the 24-hour customer service window. A workflow that starts the conversation, such as a reminder on a schedule, a new row in a spreadsheet or an order in your shop, must send an approved template instead. Use the same HTTP Request node with a template body:

{
"messaging_product": "whatsapp",
"to": "+447700900123",
"type": "template",
"template": {
"name": "appointment_reminder",
"language": { "code": "en_GB" },
"components": [
{ "type": "body", "parameters": [
{ "type": "text", "text": "{{ $json.first_name }}" },
{ "type": "text", "text": "{{ $json.appointment_time }}" } ] }
]
}
}

For a first send outside n8n, see send your first WhatsApp Business API message.

Coexistence: avoid double replies

With coexistence, a person can answer from the WhatsApp Business app at the same moment your workflow answers through the API. n8n hears about both sides of the conversation:

  • A customer’s message arrives under messages.
  • A reply typed in the app arrives at the same address as a message echo, under message_echoes. In an echo, from is your business number and to is the customer.

The template ignores echoes, because its Filter keeps only items that have messages. That is what a reply bot needs: it never answers your own team. An echo can still arrive after your workflow has already replied, so automate only the cases where a second reply does no harm:

  • Button taps and list replies. A tap on Confirm carries fixed data and needs no human judgement.
  • Clear keywords, such as “hours”, “address” or “STOP”.
  • Outside opening hours, when nobody is answering from the phone.

Send everything else to a person: post the message to your team chat, or leave it for the phone.

While the direct webhook is on, Hello no longer receives this number’s incoming messages. The WhatsApp Business app on your phone still does.

Keep a record of each conversation in your CRM

Because n8n receives customer messages, replies typed in the app and delivery statuses, the same webhook can feed a CRM. Together they show what each customer wrote, who replied and how long it took. That helps you track communication with customers and review how your team handles conversations.

To try it, add a branch before the Filter that checks whether the extracted data contains messages or message_echoes, and send each kind to your CRM node. Also log the replies that your own workflow sends, at the moment it sends them. A full CRM workflow is outside this guide.

Delivery updates, retries and duplicates

  • Track delivery. Delivery statuses arrive at the same POST address, under statuses instead of messages. Branch before the Filter, and read statuses[0].status (sent, delivered, read or failed) and statuses[0].id.
  • Answer quickly. If n8n does not answer with a 2xx status quickly, Meta sends the event again. Keep the Webhook node on Immediately.
  • Ignore repeats. A retried message has the same ID, so use it as the Idempotency-Key, or store the IDs you have processed.

Common problems

Symptom Cause and fix
Hello says the check failed, with HTTP status 404 The workflow is not published, the address uses /webhook-test/ instead of /webhook/, or the secret code is missing or different in n8n
Hello says the check failed, with HTTP status 403 The verify token in the If node is not the one in Hello’s form. Copy it again with no spaces
Hello says your plan does not include direct webhook Contact your account manager, who can enable it
The status in Hello is Not applied on Meta or Needs attention Open Webhooks → Manage. Choose Re-apply, or Refresh from Meta to compare. The message beside the status says why
Nothing appears in Executions Check that the status in Hello is Active, that the workflow is published, and that you wrote to the number you set up
Executions appear but stop at the Filter They are delivery statuses, or echoes of replies typed in the app, not customer messages. This is expected
Hello returns 401 UNAUTHORIZED The API key is wrong or disabled, or Bearer is missing in the credential
Hello returns 403 OUTSIDE_24H_WINDOW The customer has not written to you in the last 24 hours. Send a template instead
Hello returns 404 ACCOUNT_NOT_FOUND The phone number ID is not in your Hello organisation
Hello returns 400 VALIDATION_ERROR to is missing its country code, or the body shape is wrong
Customers get the same reply twice Meta retried because n8n answered slowly. Keep the POST Webhook on Immediately and add the Idempotency-Key header
You lost the verify token Open Webhooks → Manage → Change URL or token, generate a new token, and update the If node

The errors reference lists every code that Hello’s API returns.

Switching back to Hello

To stop sending the number’s events to n8n, open Webhooks → Manage for the number and choose Remove direct webhook. Meta sends the number’s events to Hello again immediately. Events that went to n8n in the meantime are not replayed into Hello.

How coexistence works →

For developers: the Hello API docs cover authentication, connecting AI agents over MCP and the message object.

Frequently asked questions

Can I use n8n’s built-in WhatsApp nodes with a number connected to Hello?

No. n8n’s WhatsApp Business Cloud and WhatsApp Trigger nodes call Meta directly, with your own Meta developer app and access token. When the number is connected through Hello, receive messages with a Webhook node and send them with an HTTP Request node that calls Hello’s API. No OAuth sign-in is needed.

Will I still see these messages in Hello’s dashboard?

No, not while the direct webhook is on. Meta sends that number’s incoming messages and delivery statuses to n8n instead of Hello, so Hello’s delivery figures for that number stop updating. Your other numbers are not affected, and removing the direct webhook sends events to Hello again at once.

Do I need a self-hosted n8n?

No. n8n Cloud and self-hosted n8n both work. The only requirement is a public HTTPS address that Meta can reach, so an instance running on your own computer needs a secure tunnel.

Can n8n send the first message to a new contact?

Only as an approved template. Free-form messages are allowed for 24 hours after the customer last wrote to you, so a workflow that starts a conversation must send a template.

Will n8n see the replies I type in the WhatsApp Business app?

Yes. With coexistence, a reply typed in the app reaches the same webhook as a message echo, with your business number in `from` and the customer in `to`. The template in this guide ignores echoes, so the workflow never answers its own team. The same events can be used to keep a record of each conversation, for example in a CRM.