Table of Contents

Hidden Fields (Get params / UTMs from url and use it as variables)

👉 Did you know that you can hyper-personalize the user experience of your bots with the Hidden Fields?

Do you want to capture UTM from your campaigns?

For example, if you already have the user's name in a param, and want to bring into Landbot so that you don't have to ask for it again 🤓

You can also keep the information you have in "in the shadow" to nurture your users' information.

Get params from URL and use it as variables

Wondering what are the Hidden Fields? Let's start from the beginning!

A URL can be used to pass information with a click.

Any word after the question mark "?" in a URL is considered to be a parameter which can hold values.

The value for the corresponding parameter is given after the symbol "equals" (=).

Multiple parameters can be passed through the URL by separating them with "&".
Hidden Fields functionality only works with lower case. If the parameter in the URL has Capital Letters, it won't be recognised

Note: The variable can only be saved in the String format.

With Landbot's Hidden Fields, you can send variables (parameters) through the URL of the bot.

Let's see how to configure them in 3 easy steps!

  1. First, go to the Builder and select the bot Settings, then select Hidden fields on the left menu:

  1. Select from the drop down how you will share the bot, either With a link or Embed into my website:

  1. Now, add the variables you want to send using the URL by typing their name and pressing enter, then click on Apply Changes.

Keep in mind that you need to use the same field names as in the URL so Landbot can match them:

  1. Add the variables to your URL. For example, if you want to use "email" and "name" as hidden fields, you need to add this:

    ?name=john&email=john@gmail.com

    And your landbot's URL should look like this:
    https://landbot.io/u/H-44687-K4QC4P5YEH0KALZ/index.html?name=john&email=john@gmail.com

 If you're using apps like MailChimp or Intercom, you can add dynamic fields to a URL so you can bulk send personalised URLs. 
Please bear in mind that for the system to accept the numbers 0 and 1, they need to be passed as decimals, like 1.0 or 0.0

Example:
?people=1.0&events=10&fines=0.0

UTM parameters

UTMs like other url parameters can be captured with the Hidden Fields functionality.

For example, in case you have an url like this:

google.com/index.html?utm_source=google&utm_medium=web

To capture with Hidden Fields utm_source and utm_medium, in the Settings > Hidden Fields section the set up will be like this:

And now the values of utm_source and utm_medium, will be available in the Landbot variables @utm_source and @utm_medium

Embedded and not embedded bots

Hidden Fields functionality will work in all types of web bots, using the regular snippet code offered

Hidden Fields functionality won't work if embedded through an iframe

Restricted keywords

These are keywords you are not allowed to use as a hidden fields (parameters) in the url:

  • location
  • welcome
  • message

The use of these words might generate an error like below:

Wordpress has restricted words, like "name", please check the full list here: https://codex.wordpress.org/Reserved_Terms

If used it will generate a 404 error

Examples of how Hidden Fields (params) are built in other platforms

1. FOR PERSONALISATION PURPOSES: Create Unique URLs for email campaigns with Mailchimp

Here is an article of how Merge Tags, are use to personalize emails to Mailchimp subscribers, this is a very common case. Thanks to Hidden Fields, you can capture the values from the merge tags and use it in your bot: https://mailchimp.com/en/help/create-unique-urls-for-subscribers/

2. FOR TRACKING PURPOSES: UTM Code

Other very common use of Hidden Fields would be to capture UTMs for tracking. Here is a little guide about UTMs, that later you can capture with Hidden Fields: https://buffer.com/library/utm-guide/

How did we do?

Custom System Messages

Landbot native SEO & Tracking tools

Contact