How do I add a tracking pixel to my thank you page?

Normally, a tracking pixel needs to be placed on the website <HEAD> section of the theme.liquid file.

  • For adding a tracking pixel that will load ONLY on thank you pages, copy the code below, replace the text with your code and paste it before the closing </head> tag. 

{% if template == "thank_you" %}

REPLACE THIS TEXT WITH YOUR TRACKING/PIXEL CODE 

{% endif %}

  • From your site admin dashboard, click the Website tab, then edit code.

  • Next, locate & click Layouts folder then click theme.liquid to open it in the code editor:

Was this article helpful?