Solved

Dynamically append subscribers email address to URL so form can be pre-filled

  • 30 January 2023
  • 5 replies
  • 578 views

Badge +2

As part of an email flow, I want to send subscribers to a landing page so we can ask questions and gather feedback. I want to dynamically append their email address to the URL so that I can use this to pre-fill the form with their email, ensuring data is captured against the correct subscriber in Klaviyo.

 

e.g. button link = {% update_property_link 'volunteering_still_interested' 'still_interested' 'https:example.com/survey?email={{ email }}' %}

icon

Best answer by alex.hong 1 February 2023, 04:20

View original

5 replies

Userlevel 7
Badge +60

Hey @samgood1 

Thanks for asking another great question. 

You can append the parameter ?email= to the URL of the page where the form is displayed. For example, if http://www.example.com?email=. No need to add {{ email }} after. Klaviyo will understand and append the user's email. Nothing extra will be required.
 

Hope this helps!

Badge +2

Hi Stephen, I test this through a campaign but no email appended to the URL. Can you link me to any documentation about this so I can make sure I’m doing things correctly?

Userlevel 7
Badge +58

Hi @samgood1,

If you haven't already we do have a Guide to Template Tags and Variable Syntax if you want to reference as well. You can embed a signup form in that page. Then use your campaign to drive users to that page.

As a note if you are looking to link track, UTM's will not append on links through the preview and it would only work through a live send.  It may be prudent to create a test campaign that sends strictly to a list of 1 or 2 people (your test or personal emails) and testing those links to ensure they're returning what you're expecting.  

An alternative method to what you're currently doing that may be a bit easier is to create a landing page on your site ( a page that is hidden from public view that you can link users to ).  This way, for that campaign you are sending you can link users to that section of your site and only have the form show on that page.  This is generally the recommended method we recommend as landing pages are re-usable should you want to pursue a similar method in the future.


me?tid=801811&ts=2022-02-15T21:23:44Z&aid=413359598791&oid=klaviyo&uuid=4af2739c-4a17-405a-b914-3b7c751d6a96

Where do I find the feature “ Autofill email if already tracked. “ as I read another post where it was said the feature got removed and indeed, I can’t find it in my form builder. Could you please direct & screenshoot where to find it? Thanks.

Userlevel 7
Badge +60

Hey @Foxy,

You’re absolutely right! As mentioned in the below Community posts the “Autofill email if already tracked” feature is no longer available as a security improvement. 

I’ve gone ahead and edited the answer accordingly. Thanks for calling this out!

Though, this doesn’t mean your site visitors don’t already have their email or phone number saved through their own browser either. Autofill is a really common browser function a number of users take advantage of which is similar to our old form setting. 

Thanks for being a part of our Klaviyo Community!

David

Reply