How to install a Retargeting/Remarketing Pixel in WordPress. (Example)

Published on
May 30, 2014
Contributors
Megan Malone
megan@vicimediainc.com

Megan Malone is a Founding Partner with Vici, and leads our Operations division.  Megan has both a radio and digital marketing background working for the Philadelphia Eagles, Beasley Broadcast Group, and Cox Media Group. In her career she has helped plan and implement thousands of digital media campaigns.   She holds a certification from Disney Institute’s People Management, Google Analytics, and was awarded the top 10 advertisers in Louisville from the American Advertisers Federation.  In her free time Megan is relaxing in Phoenix, Arizona with her husband Dave and toddler Zoey.

Subscribe to our newsletter
Read about our privacy policy.
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Retargeting web visitors is a common best practice to maximize conversions and invite back potential customers to your website. Our clients often ask us to help retarget (or remarket) their web traffic. Retargeting technology uses a pixel (lines of HTML code), which creates a cookie to track site visitors. But how the heck do you install that pixel?Wordpress doesn't make it super clear on how to do this on the footer of every page in the dashboard. So this is how it works! To add the remarketing or retargeting pixel to your WordPress site, follow these simple steps:

  1. Go to your dashboard and select Appearance (on the left hand menu bar) and then Editor.
  2. From there, you can view your Templates, followed by php files on the very right.
  3. Select the “footer.php” from the php files, scroll down to the closing body tag, and place the retargeting pixel directly above it. (Note: if you don't see "footer.php" then just hit Control or Command F on your keyboard, type in "footer.php" and hit Enter or Return. CTL+F=AWESOME)

See the examples below, using the my own custom theme, but please note your theme will probably be different. This process will work with any PHP code if just find the footer.Sample PHP before the retargeting tracking pixel has been installed (sample only — don’t use in your website’s code).<?php wp_footer(); ?><!– <?php echo BAVOTASAN_THEME_NAME; ?> created by c.bavota – https://themes.bavotasan.com –></body></html>Sample PHP after retargeting tracking pixel has been installed (sample only — don’t use in your website’s code).<?php wp_footer(); ?><!– <?php echo BAVOTASAN_THEME_NAME; ?> created by c.bavota – https://themes.bavotasan.com –><script src=”http://ib.adnxs.com/seg?add=1065823&t=1″ type=”text/javascript”></script></body></html>Have more questions? Leave a comment and we'll help you out! And don't freak out if we retarget you :)

vici digital products

UPDATE: 6-3-15, What happens if you can't find the PHP Files? It's just not there? Here's your answer(s)!Some WordPress developers build their themes with a "pixel integration area" a specific spot to place container tags and pixels.To find this area, in the WordPress menu- you can visit "Salient" and then "General Settings".Then, you can just paste the pixel in the "Google Analytics" box. Then click "Save Change".Don't have Salient? No worries! Just download your free WordPress Custom Header/Footer plugin, and paste the pixel into the footer of the plugin!

A Simple Guide to Adding the Google Remarketing Pixelhow do I install a retargeting or remarketing pixel on my wordpress sit how to install pixel retargeting or remarketing across every page of a wordpress site

Related Posts

Tips, guides, industry best practices, and news.
Category Link
What Digital Trends Should I Use In 2025?
We wanted to dig in and give you some insights into digital marketing trends that businesses should consider in 2025, focusing on strategies such as social media video, SEO (and how AI now impacts it and zero-click searches), and OTT (over-the-top) advertising.
Greg Swiszcz
May 14, 2025
Category Link
How Connected TV Caters to Holiday Shopping for Eager Consumers
The holiday shopping season is the Super Bowl of retail. Every brand, big or small, is vying for consumer attention, and traditional advertising methods just aren’t cutting it anymore. Enter Connected TV (CTV) and Over-The-Top (OTT) advertising, a game-changing strategy that allows brands to meet shoppers right where they are—on their favorite streaming platforms.
Allison Gibson
May 14, 2025
Category Link
How can I use Social Media Stories to promote my business?
Storytelling, one of society’s greatest tools in sharing the narrative that you want people to understand, has changed a lot since the days of fireside chats and Shakespearean stages. 
Greg Swiszcz
May 14, 2025