Title: Universal WP Lead Tracking
Author: Inbound Horizons
Published: <strong>9. Novembar 2022.</strong>
Last modified: 30. Septembar 2026.

---

Search plugins

![](https://ps.w.org/universal-wp-lead-tracking/assets/banner-772x250.jpg?rev=2859064)

![](https://ps.w.org/universal-wp-lead-tracking/assets/icon-256x256.png?rev=2815494)

# Universal WP Lead Tracking

 By [Inbound Horizons](https://profiles.wordpress.org/inboundhorizons/)

[Download](https://downloads.wordpress.org/plugin/universal-wp-lead-tracking.1.0.15.zip)

 * [Details](https://me.wordpress.org/plugins/universal-wp-lead-tracking/#description)
 * [Reviews](https://me.wordpress.org/plugins/universal-wp-lead-tracking/#reviews)
 * [Development](https://me.wordpress.org/plugins/universal-wp-lead-tracking/#developers)

 [Support](https://wordpress.org/support/plugin/universal-wp-lead-tracking/)

## Description

Universal WP Lead Tracking gives you important information about users from contact
form submissions on your WordPress site and allows you to instantly set up Google
Analytics events to send conversion data when someone submits a form on your website.

When you receive an e-mail from a contact form on your website, you will instantly
see data on a user’s landing page on your site, the page that they filled out the
contact form on, the referring source that sent them to your website, their location
IP (country-level) and browser/platform used.

This information is added by simply putting the `[tracking-info]` shortcode in the
email being sent to you when a user submits a form on your website. Just paste the`[
tracking-info]` shortcode in your e-mail template, and every time you receive a 
lead from your website, you will be able to see information from the user that submitted
the form.

#### The Specific Information This Plugin Provides

The tracking info specifically includes the Form Page URL, Original Referrer, Landing
Page, Lead Source, Campaign, Ad Click ID, User IP, and Browser. What do these specific
items mean?

 * Form Page URL: This is the page on your website where the user filled out your
   form.
 * Original Referrer: This is where the user came to your website from such as Google
   or Facebook. If there was no referring website, the source name is shown instead,
   such as a newsletter or „direct“.
 * Landing Page: This is the page on your website that the user first came to from
   an outside source.
 * Lead Source: This is how the user first found your website, such as Google Ads,
   organic search, social media, email, another website, or a direct visit.
 * Campaign: This is the campaign name (the utm_campaign value) from the link the
   user first clicked, when there is one.
 * Ad Click ID: This is the ad click ID (such as a Google Ads gclid) from the user’s
   first visit, when there is one.
 * Most Recent Visit: This is only included when the user came back through a different
   source or page before sending the form.
 * Most Recent Ad Click ID: This is only included when the user’s most recent visit
   was an ad click with a different click ID than their first visit. Use it to credit
   the ad that led to the form.
 * User IP: This is the IP address of the user that sent a form submission and includes
   a country location.
 * Browser: This tells you what browser a user was on when they sent a form submission.

#### Accurate Referrer And Landing Page Tracking

The referrer and landing page are captured in the visitor’s browser the moment they
arrive, so they stay accurate even on sites that use page caching. The information
is remembered for 90 days, and the visitor’s first visit is never overwritten, so
a lead who comes back days later is still credited to the source that first brought
them to your website.

The plugin recognizes Google Ads (gclid, gbraid, wbraid), Microsoft Ads (msclkid),
Facebook (fbclid), TikTok (ttclid), and LinkedIn (li_fat_id) click IDs, as well 
as UTM parameters, search engines, social networks, and other referring websites.

#### This Tracking Code Works With Most Major Form Plugins

This shortcode tracking method will work with forms on Contact Form 7, Gravity Forms,
Ninja Forms, or Elementor PRO. Because it is shortcode based, you can just drop 
in the code to the e-mail submission template on any of these major form plugins.

If you are sending your website e-mail submissions via an HTML based output on one
of these plugins, we have that covered too. Just add html=“true“ to your shortcode
like so: `[tracking-info html="true"]`

#### This Plugin Sends Form Events To Google Analytics

As an added feature, you can track any form submission on your website as a Google
Analytics event if you have Google Analytics set up on your website.

This happens automatically when you check the box for the Analytics event you want
on the plugin settings section. We currently support ga{} events for Universal Analytics
and gtag{} events for Google Analytics 4.

This will show up in your Google Analytics view as an action called „submit“ with
an event category called „Contact Form“ that you can then set as a lead source in
your conversion preferences in Google Analytics

For more plugins, help, or information about this plugin please visit [www.inboundhorizons.com](https://www.inboundhorizons.com/product/wp-universal-lead-tracking-free-wordpress-plugin/).

## Screenshots

[⌊This is the view of the plugin admin panel options you will see in Wordpress⌉⌊
This is the view of the plugin admin panel options you will see in Wordpress⌉[

This is the view of the plugin admin panel options you will see in Wordpress

[⌊This is an example of where you will enter the tracking shortcode on a web form.
This is an example from a Contact Form 7 mail form sent to the Wordpress site administrator
after a user submits a form on the site.⌉⌊This is an example of where you will enter
the tracking shortcode on a web form. This is an example from a Contact Form 7 mail
form sent to the Wordpress site administrator after a user submits a form on the
site.⌉[

This is an example of where you will enter the tracking shortcode on a web form.
This is an example from a Contact Form 7 mail form sent to the Wordpress site administrator
after a user submits a form on the site.

[⌊This is an example of the tracking information you will receive at the bottom 
of a response email when a user submits a form on your site.⌉⌊This is an example
of the tracking information you will receive at the bottom of a response email when
a user submits a form on your site.⌉[

This is an example of the tracking information you will receive at the bottom of
a response email when a user submits a form on your site.

## FAQ

### Does this plugin set a cookie?

Yes. The plugin sets one first-party cookie named `uwplt_attr` in the visitor’s 
browser. It lasts 90 days and holds the landing page, referring website, lead source,
campaign, and ad click ID for the visitor’s first visit and most recent visit. Nothing
in it identifies the visitor personally. The cookie is only read by your own website
when a form is submitted, and nothing is sent to Inbound Horizons or any other third
party. Depending on where your visitors are and your own policies, you may want 
to mention this cookie in your privacy policy or cookie consent tool.

### Does this plugin store visitor information in my database?

No. Attribution is kept only in the visitor’s cookie. Websites upgraded from earlier
versions may still have a small table named track_sessions from the old method. 
It is no longer used or written to.

### Why is the Ad Click ID or Lead Source missing for some leads?

Some browsers, extensions, and privacy settings remove tracking parameters such 
as gclid from the address before the page loads, and some visitors block cookies.
When that happens the plugin can only report what it can see, such as the referring
website or a direct visit.

## Reviews

![](https://secure.gravatar.com/avatar/c23eda3a28c68ee13faab474e89c8bd945ea9b593885945e58cb0a13a4807a34?
s=60&d=retro&r=g)

### 󠀁[Actually works = )](https://wordpress.org/support/topic/actually-works-14/)󠁿

 [bizdetail](https://profiles.wordpress.org/bizdetail/) 25. Januar 2023. 1 reply

I've been using other contact form 7 tracking plugins for YEARS, and then they started
to have issues with displaying the referring URL. Found this one, it works! Works
on ninja form, too. Highly recommended, thank you to the devs.

 [ Read all 0 reviews ](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/)

## Contributors & Developers

“Universal WP Lead Tracking” is open source software. The following people have 
contributed to this plugin.

Contributors

 *   [ Inbound Horizons ](https://profiles.wordpress.org/inboundhorizons/)

[Translate “Universal WP Lead Tracking” into your language.](https://translate.wordpress.org/projects/wp-plugins/universal-wp-lead-tracking)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/universal-wp-lead-tracking/),
check out the [SVN repository](https://plugins.svn.wordpress.org/universal-wp-lead-tracking/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/universal-wp-lead-tracking/)
by [RSS](https://plugins.trac.wordpress.org/log/universal-wp-lead-tracking/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 1.0.15 – 2026-09-30

 * FIX: The Original Referrer and Landing Page are now captured in the visitor’s
   browser when they arrive, so they are accurate on sites that use page caching.
   Previously the site itself could be recorded as the referrer.
 * FIX: Attribution is no longer lost when a cached page’s security token expires.
   The tracking script no longer uses a token, AJAX, or the database.
 * UPDATE: Attribution is now remembered for 90 days (previously 6 hours), so a 
   visitor who returns days later is still credited to the source that first brought
   them. The first visit is never overwritten.
 * ADD: The [tracking-info] shortcode now includes Lead Source, Campaign, and Ad
   Click ID lines. A Most Recent Visit line is included only when the visitor came
   back through a different source or page, along with a Most Recent Ad Click ID
   line when that visit was an ad click.
 * ADD: Recognizes Google Ads (gclid, gbraid, wbraid), Microsoft Ads (msclkid), 
   Facebook (fbclid), TikTok (ttclid), and LinkedIn (li_fat_id) click IDs, plus 
   UTM parameters.
 * UPDATE: Updated the Example Tracking Info on the settings page to show the new
   fields.
 * UPDATE: The tracking script is excluded from common caching and optimization 
   plugins so it always runs.
 * UPDATE: Click IDs of up to 255 characters and landing page URLs of up to 500 
   characters are now stored, so long Google Ads click IDs are never cut off.
 * UPDATE: Minimum required PHP version is now 7.4.
 * UPDATE: Minimum required WordPress version is now 4.5.
 * FIX: The Google Analytics event script now has an explicit version number.
 * FIX: The Google Analytics event script no longer causes a JavaScript error on
   pages that do not load jQuery.
 * FIX: A missing or unreadable IP 2 Location database file can no longer cause 
   a fatal error on PHP 8. The user’s country is left blank instead.
 * UPDATE: Confirmed compatibility with WordPress v7.1.2.
 * UPDATE: Updated IP 2 Location database to latest release of September 2026.

#### 1.0.9 – 2025-07-14

 * FIX: Added code to set tracking info by JS if not set via HTTP. Required for 
   cached pages.

#### 1.0.8 – 2025-07-08

 * FIX: Landing URLs could sometimes be set to /wp-json/ or /wp-admin/admin-ajax.
   php which is incorrect. Added a check to exclude ADMIN pages, AJAX requests, 
   REST requests, and WP-CRON requests.
 * UPDATE: Refactored some code and make it more robust.
 * UPDATE: Updated IP 2 Location database to latest release of July 2025.

#### 1.0.7 – 2025-05-20

 * UPDATE: Added a field to set a custom Google Analytics event (default event is„
   submit“).
 * UPDATE: Confirmed compatibility with WordPress v6.8.
 * UPDATE: Updated IP 2 Location database to latest release of May 2025.

#### 1.0.5 – 2024-04-03

 * UPDATE: Confirmed compatibility with WordPress v6.5.
 * UPDATE: Updated IP 2 Location database to latest release of April 2024.

#### 1.0.4 – 2024-04-01

 * UPDATE: Bumped version.

#### 1.0.3.4 – 2024-03-27

 * FIX: Fixed small bugs with „if“ checks.
 * UPDATE: Updated IP2Location database.

#### 1.0.3.2 – 2023-09-29

 * FIX: Fixed small bug causing error in background.
 * UPDATE: Updated IP2Location database.

#### 1.0.3.1 – 2023-02-01

 * TWEAK: Cleaned up some code and clarified wording on settings page.
 * ADD: Added IP lookup functionality to find country based on IP address. IPv6 
   requires the GNU Multiple Precision (GMP) extension to be installed.

#### 1.0.3 – 2023-01-25

 * TWEAK: Changed some wording on admin page and edited readme.txt

#### 1.0.2 – 2022-11-04

 * TWEAK: Tested with WordPress v6.1

#### 1.0.1.3 – 2022-10-28

 * FIX: Escaped HTML and Scripts

#### 1.0.1.2 – 2022-10-27

 * TWEAK: Updated readme

## Meta

 *  Version **1.0.15**
 *  Last updated **1 week ago**
 *  Active installations **100+**
 *  WordPress version ** 4.5 or higher **
 *  Tested up to **7.1.3**
 *  PHP version ** 7.4 or higher **
 *  Language
 * [English (US)](https://wordpress.org/plugins/universal-wp-lead-tracking/)
 * Tags
 * [contact](https://me.wordpress.org/plugins/tags/contact/)[email](https://me.wordpress.org/plugins/tags/email/)
   [form](https://me.wordpress.org/plugins/tags/form/)[lead](https://me.wordpress.org/plugins/tags/lead/)
   [tracking](https://me.wordpress.org/plugins/tags/tracking/)
 *  [Advanced View](https://me.wordpress.org/plugins/universal-wp-lead-tracking/advanced/)

## Ratings

 5 out of 5 stars.

 *  [  1 5-star review     ](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/?filter=5)
 *  [  0 4-star reviews     ](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/?filter=4)
 *  [  0 3-star reviews     ](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/?filter=3)
 *  [  0 2-star reviews     ](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/?filter=2)
 *  [  0 1-star reviews     ](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/universal-wp-lead-tracking/reviews/)

## Contributors

 *   [ Inbound Horizons ](https://profiles.wordpress.org/inboundhorizons/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/universal-wp-lead-tracking/)