Determine Webpage Signup Location

This feature requires Manager user level or higher.

If you embed your signup form on multiple webpages like a homepage, a contact page, and a product site, you may want to find out where subscribers signed up.

To do this, you'll edit your form to include a hidden field that pre-fills a webpage location value, like homepage or contact page. This value will appear in the profile of new subscribers from the embedded form. Later, you can use this location value to segment your list and send targeted content to subscribers who came from a certain page.

In this article, you'll learn how to track signup locations with MailChimp's embedded signup form.

Before You Start

  • Use the process described in this article only if you want more details about the page where embedded form subscribers are coming from. If you want to see how subscribers signed up, like through the hosted form, embedded form, or an integration like Facebook, segment your list by signup source instead.
  • This is an advanced feature and is recommended for users familiar with custom coding. Contact your developer, or hire a MailChimp Expert if you need assistance.

Task Roadmap

This is a multi-step process, and you’ll need to complete these steps in order.

  • Add a hidden text field to your signup form in MailChimp.
  • Copy the form’s embed code.
  • Edit the form for each webpage you want it to appear on.

After the form is updated and added to webpages on your site, you can test your form, and create auto-update segments to organize new subscribers by webpage signup location.

Add a Hidden Field

To get started, you'll add a hidden text field to your form.

  1. Navigate to the Lists page.
  2. Click the drop-down menu next to the list you want to work with, and choose Signup forms.
  3. Select General forms.
    Select general forms
  4. Click the Forms and response emails drop-down menu, and choose Signup form.

  5. Navigate to the Build it tab.
    A screenshot of the form builder's Build It tab.
  6. Look for the Add a field tab, and click Text.
      A text field in the form builder
  7. On the Field settings tab, input a Field name and Field tag.
  8. Under Field visibility, click Hidden.
  9. Click Save Field.

Now that you've added a hidden field to your form, you’ll copy the form’s embed code.

Get the Embed Code

To copy the form's embed code, follow these steps.

  1. From the Form Builder, click Signup forms.
  2. Select Embedded forms.
    Select embedded forms
  3. Choose Classic, Super Slim, or Naked from the form options.
  4. Under the Copy/paste onto your site heading, click the code to highlight your form. Use CTRL+C or CMD+C on your keyboard to copy it.

Before you post the embed form code on your site, you’ll add one small piece of code into your form that will prefill the hidden field with the location information you provide.

Modify Embed Code

To modify the form code, follow these steps.

  1. Paste the form code into a HTML or plain-text editor, and use CTRL+F or CMD+F on your keyboard to search for “form action.” You’ll find it near the beginning of your form’s code. This is your form action URL, which will look similar to this example.

    form action=”//mailchimp.com.us8.list-manage.com/subscribe/post?u=e5baa4823db5b71c884700f56d&id=d12bb1307f7
  2. At the end of the code for your form action URL, add &MERGE=value.
    Replace MERGE with your hidden field’s tag, and replace value with the form location information you’d like to send to MailChimp. For example, to prefill the value Homepage in a hidden field called SIGNUP, add &SIGNUP=Homepage to the end of the form action URL.

  3. After you update the form, copy the code, and paste it onto your site.

Repeat steps 1-3 to edit additional copies of the code for each page where you want to embed the form.

Test Your Form

To test your updated signup form, fill it out completely on your site and submit it. If you’ve pasted the form in several places, use different email addresses for each test submission.

After you've confirmed your subscription, search MailChimp for your subscriber profile, then find your hidden field’s label and look for the value you used. If everything is set up correctly, your profile will have signup location information in this field. 

Screenshot of subscriber details section

Create Segments

Most people use data from prefilled hidden fields to create segments that track where subscribers came from. Create a segment to show all subscribers whose default merge tag value is “Homepage,” “MarketingSite,” or any other hidden text value you prefilled in your embedded forms. Remember, segments based on text fields are case-sensitive.

A screenshot of choosing the segment criteria to create a signup location segment.

To keep track of signups from a specific page, save the segment and check the box next to auto-update.

A screenshot of the save process for an auto-update segment.

When new subscribers sign up on your embedded form, we’ll automatically add them to the segment you created.

Was this article helpful?
What can we do to improve articles like this?