XF 2.0 Tracking Pixel For Registrations


I am new to Xenforo but very excited to get started :)

Could someone please help me insert a tracking pixel into the header of my Registration Complete template?
I searched the forum and found this solution posted in the past:
<xen:container var="$head.tracker">Your code here</xen:container>
But it was written for Xenforo 1.5, and I'm using 2.0 and not sure if it still applies.



Well-known member
<xf:head option="tracker">Your code here</xf:head>
Would the 'your code here' be the actual scrip code or just the # of your pixel?

I am trying to put it on every page as well, should i add this to the page container instead or?

Chris D

XenForo developer
Staff member
If you want it on every page it’s best in the helper_js_global template inside one of the macros there.

The header one is for the header, the body one is in the footer depending on where it needs to be loaded. If it relies on jQuery then its best in the body macro.

You’d need to include all of the relevant code given to you by the provider.