← Blog

·

Elementor form + official WhatsApp Business API

Updated on November 24, 2026

To send a WhatsApp message when someone fills out an Elementor form, you connect the form submission to the official WhatsApp Business API, which sends a Meta-approved template to the number entered. There are two routes: the Webhook action under “Actions After Submit”, which hands the data to a tool such as n8n or Make, or the elementor_pro/forms/new_record PHP hook, which calls the API straight from WordPress. Both need a phone field and the person’s consent.

This guide covers both routes, the confirmation template and what each message costs.

WhatsApp button vs. a form that sends WhatsApp

These are different things, and many people search for one thinking it is the other:

WhatsApp button or linkForm + official API
Who sends the first messageThe visitor, by tapping the buttonYour business, automatically
Needs the APINoYes
Needs an approved templateNoYes
Where the data is recordedOnly in the chat on the phoneIn WordPress, your CRM and the API log
In ElementorFloating button or dynamic contact URLForm widget (Elementor Pro)

Elementor has a floating button with a WhatsApp option and a dynamic contact URL for WhatsApp. If all you want is to open a chat, see WhatsApp button on WordPress without a heavy plugin. This article covers the other case: the visitor submits the form and receives a confirmation on WhatsApp, sent by your business.

Prepare the form

In the Elementor Form widget:

  1. Phone field. Use the Tel type, which validates phone formatting. In the help text, ask for the country and area code.
  2. Consent field. An acceptance (checkbox) field with text such as “I agree to receive the confirmation and follow-up from Example Company on WhatsApp”. Meta requires that people agree to receive messages from your business and know who will send them (Get opt-in for WhatsApp).
  3. Field IDs. On each field, in the Advanced tab, set a short, stable ID: name, whatsapp, interest, optin. The code relies on these IDs.
  4. Form name. Give it a unique name (for example, website-quote) so the code knows which form to handle.

Personal data handling falls under the privacy law where you operate; in Brazil, that is the LGPD (Law 13,709/2018). Settle the legal basis and retention period with your lawyer; this article is not legal advice.

Want to try it while you read? Create a Vectalk account and send your first message through the official API. Create free account →

Create the confirmation template

The message goes out with no open conversation, so it must be an approved template. Example quote_confirmation, suggested category utility:

Hi {{1}}! We received your quote request for {{2}}. Reference {{3}}. A consultant will reply here within 1 business day.

Suggested button: “Talk to the team” (quick reply), which opens the customer service window when tapped. Meta sets the category during review (template categorization). If the copy includes a discount or a call to buy, the template becomes marketing. See how to build and get templates approved in WhatsApp API message templates.

Route 1: the Webhook action to n8n or Make

Under Actions After Submit, add Webhook, open the section that appears and paste your automation’s trigger URL, as the Actions After Submit help page describes. On each submission, Elementor sends the form fields to that URL.

In n8n, the flow looks like this:

  1. Webhook (POST method) receives the form data.
  2. IF checks that consent was ticked and a phone number is present.
  3. Code or Set cleans the number (digits only, with the country code).
  4. HTTP Request calls the WhatsApp API with the template JSON.

Elementor’s official help does not spell out the exact payload format (key names and encoding). Before you build the flow, submit a test entry and look at how the fields arrived in n8n’s Webhook node. The HTTP node walkthrough is in n8n with the WhatsApp Business API; in Make and Zapier the logic is the same (WhatsApp API with Make and Zapier).

When to choose it: you already use n8n or Make, you also want to push the lead to a CRM and a spreadsheet, and you’d rather not touch PHP.

Route 2: a PHP hook in WordPress

Elementor Pro fires the elementor_pro/forms/new_record hook after the form actions run. The developer documentation shows how to read the form name with $record->get_form_settings( 'form_name' ) and the fields with $record->get( 'fields' ). The code below goes in a small plugin (or in your child theme’s functions.php):

<?php
/**
 * Plugin Name: Elementor -> WhatsApp (official API)
 */

add_action( 'elementor_pro/forms/new_record', 'vt_elementor_whatsapp', 10, 2 );

function vt_elementor_whatsapp( $record, $handler ) {
    if ( 'website-quote' !== $record->get_form_settings( 'form_name' ) ) {
        return;
    }

    $fields = [];
    foreach ( $record->get( 'fields' ) as $id => $field ) {
        $fields[ $id ] = $field['value'];
    }

    if ( empty( $fields['optin'] ) || empty( $fields['whatsapp'] ) ) {
        return;
    }

    $phone = preg_replace( '/\D/', '', $fields['whatsapp'] ); // expects country code

    $payload = [
        'messaging_product' => 'whatsapp',
        'to'                => $phone,
        'type'              => 'template',
        'template'          => [
            'name'       => 'quote_confirmation',
            'language'   => [ 'code' => 'en_US' ],
            'components' => [
                [
                    'type'       => 'body',
                    'parameters' => [
                        [ 'type' => 'text', 'text' => $fields['name'] ?: 'there' ],
                        [ 'type' => 'text', 'text' => $fields['interest'] ?: 'our services' ],
                        [ 'type' => 'text', 'text' => strtoupper( wp_generate_password( 6, false ) ) ],
                    ],
                ],
            ],
        ],
    ];

    $response = wp_remote_post( 'https://apis.vectalk.com.br/api/messages', [
        'headers' => [
            'Authorization' => 'Bearer ' . VECTALK_TOKEN,
            'Content-Type'  => 'application/json',
        ],
        'body'    => wp_json_encode( $payload ),
        'timeout' => 15,
    ] );

    if ( is_wp_error( $response ) ) {
        error_log( 'WhatsApp: ' . $response->get_error_message() );
    } elseif ( 200 !== wp_remote_retrieve_response_code( $response ) ) {
        error_log( 'WhatsApp: ' . wp_remote_retrieve_body( $response ) );
    }
}

And in wp-config.php, outside version control:

define( 'VECTALK_TOKEN', 'your_instance_token' );

Things to watch with this route:

  • Response time. The call runs during form submission. With a 15-second timeout and the API down, the visitor waits. On high-traffic sites, save the lead and send from a queue (WP-Cron or Action Scheduler).
  • Checkbox value. Check in a test submission what the acceptance field stores in value and adjust the optin test.
  • Reference. The example generates a random code. If the lead goes to a CRM, use the ID the CRM returns.
  • Spam. Turn on the form’s reCAPTCHA or honeypot. Bots submitting other people’s numbers trigger messages to people who never asked, which leads to blocks and reports.

When to choose it: you have access to the site’s code, you don’t want to depend on an external tool and you want everything logged inside WordPress.

Which route to choose

CriterionWebhook + n8n/MakePHP hook
Coding requiredLittle or noneYes, PHP
Extra tooln8n, Make or ZapierNone
Send the lead to CRM and spreadsheet at the same timeEasyMore code
Data formatCheck with a test submissionDocumented in the hook
Impact on form submissionLowDepends on the timeout

If your form is Google Forms or Typeform, the logic is similar; see Google Forms and Typeform + WhatsApp. For leads coming from Google Ads lead forms, see Google Ads lead form + WhatsApp.

What it costs

Meta charges per delivered message, and the rate depends on the recipient’s country. For recipients in Brazil, since October 1, 2026: utility BRL 0.0350 and marketing BRL 0.3217 (pricing). A site with 800 quote requests a month, each with one utility confirmation, spends 800 × BRL 0.0350 = BRL 28.00 with Meta. If the template is classified as marketing, the same math gives BRL 257.36.

When the customer replies, the customer service window opens and your team’s replies are service messages: 1,000 free per month per number, billed from the 1,001st on. Model your case in the cost calculator.

How to do it with Vectalk

Vectalk is a proxy for the official WhatsApp API: the PHP code and the n8n HTTP node use https://apis.vectalk.com.br/api/messages with the same JSON as the Cloud API. Create an instance token (required for templates), build the template in the dashboard with help from the Template Library and register the webhook that receives replies and delivery statuses, in Meta’s format (webhooks).

Billing is a monthly plan plus a prepaid balance, and each delivered message is deducted from the balance, with no card in Meta. Vectalk has no built-in inbox: conversations started by the form are answered in the system you already use. See the documentation or create an account.

Frequently asked questions

Does free Elementor include the Webhook action?

The Form widget and Actions After Submit are part of Elementor Pro. On the free version, use a form plugin that supports webhooks, or the PHP route with a different form.

Can I send the message to my team’s WhatsApp instead of the customer’s?

Yes: change to to your team’s number. The same rule applies: outside an open conversation, only approved templates. For internal alerts, an email or a CRM notification is usually simpler.

Do I need a WhatsApp plugin for WordPress?

Not for this flow. The PHP hook or the Webhook action already calls the API. Button plugins serve a different purpose: opening a chat from the site.

Is the template approved instantly?

There is no guaranteed turnaround or approval. Meta reviews the copy and sets the category. Submit the template before you publish the form.


Official sources checked on November 24, 2026: Elementor: Form widget, Elementor: Actions After Submit, Elementor: form hooks, Elementor: floating button, Elementor: dynamic contact URL, WhatsApp: opt-in, WhatsApp: template categorization, WhatsApp: pricing, Vectalk documentation.

Put your business on the official WhatsApp

Create your account, connect your number to the official API (you can keep the app with coexistence) and start serving customers and sending messages.