Leadpages
Add Rybbit analytics to your Leadpages landing pages
Every Leadpages page, site and pop-up has an Analytics tab in its builder settings with a Head Section Tracking Code field, and that is where the snippet goes. In the site builder the setting is site-wide, so one paste covers every page of the site; landing pages built on their own are tracked one page at a time.
Get your tracking snippet
In your Rybbit dashboard, open Site Settings → Tracking Script and copy your snippet. It looks like this:
<script src="https://app.rybbit.io/api/script.js?siteId=YOUR_SITE_ID" defer></script>YOUR_SITE_ID is the numeric ID of your site. If you self-host Rybbit, app.rybbit.io is the domain of your own instance.
Add the snippet to Leadpages
- Open the site or landing page in the builder.
- Click the Settings gear in the left-hand sidebar, then the Analytics tab.
- Paste the snippet into Head Section Tracking Code.
- Click Save, then Update to push the change to the published page.
Repeat for each standalone landing page you want tracked. For sites, the code applies to every page in the site.
Pop-ups have the same tracking code fields in their settings, but a pop-up shown on a page that already carries the snippet does not need its own copy.
Verify installation
Open your live site in a new tab and click through a few pages. Within a few seconds the pageviews appear in the Rybbit dashboard.
If nothing shows up:
- View the page source and search for
script.js?siteId=to confirm the snippet is on the page. - Open the browser Network tab and check that
script.jsreturns200and thatPOSTrequests go to/api/track. - Disable ad blockers, or set up a proxy so the script loads from your own domain.
- See the script troubleshooting guide for other common causes.
Troubleshooting
- Snippet not in the page source: the page was saved but not updated. Click Update in the builder to republish.
- Standalone pages missing: tracking code on a site does not extend to landing pages published outside that site. Add the snippet to each one.
- GA4 Measurement ID field: the Analytics tab also has a field for a Google Analytics ID. That field is for GA4 only; the Rybbit snippet belongs in Head Section Tracking Code.
Next steps
- Track custom events such as signups, purchases and button clicks.
- Identify users to connect sessions to accounts.
- Proxy the script through your own domain to bypass ad blockers.
- Script attributes let you skip or mask URLs and tag events.