Need help? You’ve come to the right place

What’s New Getting Started Building Integrating Publishing

Third-party tracking and analytics

Last Updated

While we provide built-in analytics for all of your pages and pop-ups, you can also use third-party analytics or tracking code. Tools like Google Analytics and Facebook’s Pixel provide powerful metrics so you can get even more data on your pages and forms’ performance.

In this guide, you’ll also learn where you can paste third-party tracking code in sites, pages, or pop-ups, as well as edit search engine keywords and social media previews.

NOTE: We can’t provide support for specific questions about your third-party tracking service. Learn more…

The fine print

Here are some notes to keep in mind while you work with third-party analytics and tracking code:

  • Modifying your page or site’s code can cause issues on your pages or pop-ups. Take care to properly configure your tracking code according to its documentation, and avoid entering other codes in the tracking code sections.
  • Some services calculate metrics differently than our system, so in some cases, third-party data will differ from our numbers. More info…
  • All tracking and third-party analytics in the site builder are site-wide, rather than page-specific.
  • While Leadpages provides the ability to utilize third-party analytics, we do not support the implementation or customization of them.

NOTE: In the video, you may notice the 'Page Tracking' tab, which was what this tab was called in our retired Builder; it has since been renamed 'Analytics'.

Access settings

Each page, site, or pop-up has a set of global settings. You can access them in the builder’s left-hand sidebar by clicking the settings gear icon.

Installing Third-party analytics (i.e. Facebook Pixel, Google Analytics)

Determine where to install your code

Before getting started, you’ll need to find out where your code should be installed. Check your tracking service’s documentation for their recommendation. Typically, they’ll suggest placing the code in the <head> or <body> section.

You’ll also want to determine which destination to paste your code onto. Some services require you to paste their code on a “thank you” or confirmation page. Other tools might instruct you to install the code on your opt-in page itself.

You can find installation guides for Google and Facebook below:

If you’re using a different service, visit their site to find out where they recommend pasting their tracking code.

Google Analytics 4

Leadpages has a quick and simple way to get your Google Analytics 4 (GA4) tracking code running on your page utilizing a Google Analytics 4 Measurement ID.

To begin tracking GA4 in Leadpages, you’ll need a Google Analytics account, a property, and within that property you’ll need a data stream, which will contain your Measurement ID.  → Here’s where to find your Measurement ID

Within the Settings section of the Leadpages builder, you can paste your Google Analytics 4 Measurement ID (i.e. G-123456789) under the Analytics tab.


NOTE: This field is currently for GA4 only. If you're using Google Tag Manager, you'll want to utilize the tracking code sections detailed in the article linked below to paste the entire tracking code onto your page.
WARNING: If you currently use Google’s Universal Analytics ID with your assets, we recommend you begin transitioning to Google Analytics 4 (GA4). Google provides a guide to making the switch to GA4 here.

Facebook Pixels

Before following the steps below, you'll want to grab your Facebook Pixel code within the Facebook Ads Manager. We've got a couple of videos here to help you out!

NOTE: Because of the nature of how quickly Facebook changes its ads management platform, it's best to follow their directions here for the most up-to-date pixel creation process.

Access your Facebook Pixel

Add Facebook Pixels to Leadpages

Pages and sites

Here’s where you can install your tracking code in our pages and sites:

  1. Create or open a landing page site where you’d like to install your code. Click the Settings tab in the left-hand sidebar.
  2. Select the Analytics tab.
  3. Paste your tracking code in one of the fields provided, according to instructions from your analytics service provider.
  4. Click Save, then Update.

NOTE: Code pasted into the <body> section of a pop-up will always appear at the beginning of the <body> section.


Here’s where you can install your tracking code in our pop-ups:

  1. Create or open a pop-up where you’d like to install your code. Click the Settings tab in the left-hand sidebar.
  2. Paste your tracking code in one of the fields provided, according to instructions from your analytics service provider.
  3. Click Save, then Update.


Search engine optimization (SEO)

Search engine optimization (SEO) is a complex topic, so we won’t cover all the details here. The good news is that a lot of best practices are built into Leadpages already—such as mobile responsiveness and structured HTML.

For additional tips, check out Google’s Webmaster Guidelines. While you may not be able to implement every single best practice, their guide provides handy advice for optimizing your pages.

Finally, you can set the title, keywords, and description of any page or site in the Settings tab under the SEO tab.


If you’re unsure what to put in your page or site’s SEO fields, review this article from Google: Create good titles and snippets in Search Results ↗

Some Leadpages users want to make sure they have an SEO H tag on their page or site. You can make sure of this by using the text widget, as each headline text type within the text widget corresponds with an H tag like so:

  • Headline 1 = <h1>
  • Headline 2 = <h2>
  • Headline 3 = <h3>

Facebook Preview

Editing the title, description, and Facebook thumbnail image will impact the preview of your page or site when you share it on social media. Some fields will also transfer over to other social networks. Learn more here. ↗

Frequently asked questions

Why is Google Analytics registering more than one domain?

At times, Google Analytics will register more than one domain under a single contact if you have your pages published to a domain you own, as these pages are also published on your Leadpages Domain. If you'd like the analytics to only register your custom domain, you'll want to add your Leadpages Domain (i.e. to the Referral Exclusions list in your Google Analytics account. 

Do third-party analytics work with Leadpages published to WordPress or my server?

Yes! As long as you include the code on your page or site, it should work with all of our publishing options, including WordPress. If you use our Advanced HTML export feature, it’s usually best to paste your tracking code right within your page or site’s source code (rather than in the builder).

I need help setting up my tracking code… what are my options?

As much as we’d like to help, we’re not able to provide direct support for third-party analytics platforms. That said, many top services have excellent guides that cover everything from setup to troubleshooting advice.

If you’re still stuck, you might try reaching out to your analytics service’s support team—or, if they don’t offer one-on-one support, check for a forum, such as those for Google and Facebook:

That said, don’t hesitate to reach out to us if you have issues or questions about anything within Leadpages.

Need more help?

You can always get in touch with our support team—just click Support in your Leadpages navigation menu, or submit a ticket ↗

Was this article helpful?
Powered by Zendesk