A Contact Form 7 popup with OTP verification shows your form in a popup window and makes visitors verify their mobile number with an SMS one-time password (OTP) before they submit it. You build it in two parts: first add the SMS ALERT PHONE field to your Contact Form 7 form, then place that form inside a popup created with the free Popup Builder plugin.

New to the plugin? Install it and connect your account with the WordPress SMS plugin setup guide.

Before you start

  • Install and activate Contact Form 7, the Popup Builder plugin, the SMS Alert plugin and connect your SMS Alert account.
  • Keep SMS credits in your account. Every OTP uses credits.
  • On India routes, the OTP message must match an approved DLT template. See Convert into DLT Template.

Part 1: Build the OTP form

  1. In the WordPress dashboard, open Contact Form 7 and edit the form you want to show in the popup.
  2. In the tag generator, insert the SMS ALERT PHONE field (labelled “SMS Alert Phone”).
  3. Tick “Use this field for sending OTP to Mobile Number”.
  4. Click Save, then copy the form’s shortcode shown at the top of the form editor.

For the full OTP setup, including the visitor experience and settings, see Contact Form 7 OTP verification.

Part 2: Create the popup

  1. In the WordPress dashboard, go to Popup Builder and click Add New.
  2. Under Add New Popup, choose HTML.
  3. Paste the Contact Form 7 shortcode into the popup content.
  4. Under Display Rules, set when and where the popup should appear, for example on a page, after a delay or on a button click.
  5. Save the popup and publish it.

Show the popup

The display rules show the popup automatically. To show it somewhere you choose, paste the popup’s own shortcode where you want it, for example on a button or a page.

To test, open the page in a private window, trigger the popup, enter a mobile number, verify the OTP and submit the form.

Troubleshooting

Problem

What to check

The popup does not appear

Check the display rules and that the popup is published.

The form appears but has no OTP step

Check that the form uses the SMS ALERT PHONE field with the OTP option ticked, and that you pasted the shortcode of the saved form.

No OTP arrives

Check credits, the mobile number format, the sender ID, DLT approval and the delivery report. See Unable to Send OTP from WordPress Plugin.

The OTP step attaches to the wrong form

Several forms with the SMS Alert phone field on one page may conflict. Test with one form per page.

The form is cached or outdated

Clear your page cache and the popup builder cache after editing the form.

The OTP is rejected on India routes

The text does not match your approved DLT template. See Template Mismatch Error.

Frequently asked questions

How do I put a Contact Form 7 form in a popup with OTP verification?

Add the SMS ALERT PHONE field with the OTP option to the form, copy the form’s shortcode and paste it into an HTML popup in Popup Builder.

Contact Form 7, Popup Builder and the SMS Alert plugin.

In the Display Rules of the popup in Popup Builder.

Yes. Paste the popup’s shortcode where you want it.

Yes. Each submission needs a fresh OTP verification.

Yes, for every OTP.

Yes. Other popup plugins can show a Contact Form 7 form, but some may conflict with the OTP step. Popup Builder is the plugin this guide documents, so test any other popup plugin in a private window before you publish.

Still can't find the solution for your Query?

Contact Support