Loading tutorials…
Loading tutorials…
WordPress is the trickiest pixel install of the major platforms because there's no native channel app. You have two real options: a dedicated pixel plugin or a GTM container. Picking wrong means rebuilding in 6 months.
Who this is forWordPress site owners (WooCommerce, lead-gen, or content sites) running Meta Ads who want the right install path the first time. Especially relevant if your site already runs GTM for other tracking — that changes the recommended path.
What you'll need
Step 1
If you already run GTM for anything (GA4, conversion tracking), use GTM. If WordPress is your only tracking surface and you do not run GTM, use a pixel plugin.
Path A — Pixel plugin (PixelYourSite Free, Pixel Caffeine, or similar). Pros: zero coding, handles WooCommerce events natively, CAPI built-in (paid tier). Cons: one more plugin to maintain, paid tier required for full CAPI.
Path B — Google Tag Manager. Pros: consolidates ALL tracking (Meta + GA4 + LinkedIn + TikTok) in one container, easier to version-control, free. Cons: requires understanding GTM triggers and variables.
Decision rule: if you already have a GTM container with anything in it, use Path B. The marginal effort of adding Meta Pixel to GTM is much smaller than maintaining two separate tracking systems.
For WooCommerce stores specifically: PixelYourSite Pro auto-handles the e-commerce event taxonomy (ViewContent, AddToCart, InitiateCheckout, Purchase with values) which is otherwise tedious in GTM.
This tutorial walks both paths. Choose the section that matches your stack.
Step 2
Plugins → Add New → search "PixelYourSite." Install + activate the Free version (or Pro if you have a WooCommerce store).
WordPress admin → Plugins → Add New → search "PixelYourSite." Install and activate.
A new menu item "PixelYourSite" appears in the sidebar. Open it.
Settings tab → enter your Meta Pixel ID (found in Events Manager → Settings → Pixel ID).
Enable Advanced Matching → toggle ON every available field (email, phone, name, address). The plugin auto-collects these from logged-in users and WooCommerce orders.
For WooCommerce: enable the WooCommerce integration in the plugin's WooCommerce tab. Confirm event mapping — ViewContent should fire on product pages, AddToCart on add-to-cart actions, Purchase on order completion.
Save. Visit your homepage in incognito. The Meta Pixel Helper Chrome extension should show exactly one pixel with the correct ID.
Step 3
In your GTM container, create a Custom HTML tag with the Meta Pixel base code, fired on All Pages with the new Consent Mode v2 gating.
In Events Manager → Settings → Pixel → "Continue Pixel Setup" → "Manually Add Pixel Code." Copy the base code (it starts with the !function(f,b,e,v,n,t,s) snippet).
In GTM → Tags → New → Tag Configuration → Custom HTML. Paste the Meta Pixel base code in the HTML field.
Important: in the Advanced Settings → Tag firing options, set "Once per page." Set Tag Sequencing to fire AFTER your Consent Mode tag if you run one.
Trigger: All Pages. Save the tag.
For each Meta event (ViewContent, AddToCart, InitiateCheckout, Purchase): create a separate Custom HTML tag with the fbq("track", "EventName", {...params}) code. Fire on the appropriate event trigger (e.g., DataLayer Event "add_to_cart" → fire AddToCart tag).
Publish the container. Visit your site. Meta Pixel Helper should show the pixel firing with the correct ID.
Step 4
Browser pixel alone misses 20-30% of post-iOS conversions. CAPI sends events server-side and recovers most of it.
For Path A users: PixelYourSite Pro includes a CAPI Gateway feature. In PixelYourSite → Conversions API → enter the CAPI Access Token (generated in Events Manager → Settings → Conversions API → Generate Access Token). Save. CAPI now fires alongside the browser pixel.
For Path B users: the cleanest path is server-side GTM (sGTM) hosted on Stape or your own Cloud Run instance. This is a 2-3 hour setup on its own — see our 'Set up Meta Conversions API' tutorial for the full walkthrough.
A cheaper Path B alternative: use a WordPress CAPI plugin (CAPI for Meta Pixel by ScribeHow, etc.) that handles server-to-server posting from your WP hosting. Less robust but functional for low-volume sites.
After enabling CAPI, validate in Events Manager → Test Events. Each event should now appear with both a 'Browser' and 'Server' badge. If you only see one, deduplication is not configured.
Step 5
Browser and server events firing for the same action MUST share an eventID. Without it, Meta counts the same purchase twice.
For Path A (PixelYourSite Pro): event deduplication is automatic — the plugin generates matching eventIDs for browser + server events. Verify in Events Manager → Settings → Event deduplication → status should read "Set up."
For Path B (GTM): you must explicitly pass an eventID variable in BOTH the browser fbq() call AND the server-side request. The cleanest pattern is generating a UUID per event in the GTM data layer and reading it from both places.
If event deduplication is misconfigured, Events Manager will show a yellow warning banner. Reported conversions inflate by 30-100% until fixed.
Step 6
Place a test order or submit a test lead form in incognito. Wait an hour. Verify both browser and server events appear in Events Manager.
Open incognito. Visit your site through a Meta ad URL (or use Test Events with your browser ID for direct testing).
Complete the full conversion path: view product → add to cart → checkout → purchase. Or: page → form → submit.
In Events Manager → Test Events tab, enter the browser test ID and watch events stream in real time. You should see ViewContent, AddToCart, InitiateCheckout, Purchase (or PageView → Lead) firing in sequence.
For each, confirm both a Browser pill and a Server pill appear. The Deduplication column should read "Deduplicated."
Wait 60 minutes, then check the Overview tab. Test events disappear from Test Events after the session but should now appear in the daily Overview counts.
Step 7
In Business Manager → Brand Safety → Domains, verify your WordPress domain. Required before you can configure Aggregated Event Measurement.
Business Manager → Brand Safety → Domains → Add domain. Enter your bare domain (example.com, not www.example.com).
Choose verification method: Meta-tag (paste into header.php), DNS TXT record (add via your registrar), or HTML file upload.
Meta-tag is easiest for WordPress: copy the tag, paste it inside the <head> section of your theme. In WordPress, this is usually in Appearance → Theme File Editor → header.php, or via a plugin like Insert Headers and Footers.
Click "Verify Domain." Confirmation usually appears within 10 minutes for meta-tag method, 24 hours for DNS.
Domain verification unlocks Aggregated Event Measurement — see our AEM setup tutorial for the rest of that flow.
Common mistakes
Installing both the channel app AND a plugin
What goes wrong: Stack Meta Pixel by Meta + PixelYourSite + manual GTM tags and you can have three pixels firing for the same event. Conversions counted 3x, ROAS reads 3x reality, Advantage+ optimizes toward fantasy targets. Typical waste: 30-50% of ad budget over 60 days.
How to avoid: Pick ONE install path. If you find multiple, disable all of them, then reinstall just one cleanly. Use Meta Pixel Helper to verify exactly one pixel fires.
Not testing through your caching plugin
What goes wrong: You verify the pixel works in incognito (which bypasses cache). For logged-out cached visitors, the cached HTML may not include the pixel. Anonymous users — i.e. most of your ad traffic — never trigger events.
How to avoid: In your caching plugin, exclude the pixel JS file from minification and deferral. Test by visiting your site in a regular browser window after clearing cache — Meta Pixel Helper should still detect the pixel.
Skipping Advanced Matching entirely
What goes wrong: Without Advanced Matching, iOS 14.5+ devices lose 25-40% of attribution. For US e-commerce (~60% iOS share), that's a meaningful chunk of post-iOS performance just leaking.
How to avoid: PixelYourSite → Advanced Matching → toggle all fields on. For GTM users, add user-data parameters (email, phone, name) to your event tags. Verify Event Match Quality 7+ days after enabling.
Not configuring Consent Mode v2
What goes wrong: In EU and increasingly globally, firing the pixel before consent violates GDPR/PIPEDA and exposes the business to fines. Meta also degrades signal for accounts that ignore consent — modeled conversions decline 15-30%.
How to avoid: Install a Consent Management Platform (Cookiebot, OneTrust, Iubenda Free). Configure Meta Pixel to fire ONLY after marketing consent. In GTM, gate the pixel tag with a consent-state variable.
Firing Lead events on every form submit (including spam)
What goes wrong: Your form gets 50 spam submissions a day. Lead event fires 50x daily. Meta sees a sudden flood of cheap leads and starts spending budget on more spam-likely audiences. CPL on real leads doubles.
How to avoid: Add a server-side validation step before firing Lead. Either fire from the form plugin's "valid submission" hook (after honeypot/reCAPTCHA passes), or fire Lead only on a thank-you page that spam bots typically don't reach.
Leaving the pixel installed when you stop running Meta Ads
What goes wrong: When you pause Meta Ads for 3+ months but leave the pixel firing, Meta still receives all visitor data. If you ever turn ads back on, that historical data is dated and your initial CPM is inflated 30-50% as Meta re-learns your audience.
How to avoid: If you genuinely pause Meta Ads long-term, disable the pixel until you're ready to relaunch. Don't pause-and-leave — Meta uses recency as a signal.
Recap
Done — what's next
How to install the Meta Pixel via Google Tag Manager
Read the next tutorial
Hand it off
WordPress pixel installs are deceptive — they look simple until plugin conflicts surface 30 days in and conversion data starts disagreeing with your e-commerce dashboard. A Meta Ads specialist on EverestX will install once, audit your plugin stack, configure CAPI cleanly, and monitor EMQ. Typical setup: $80-160 at $14-16/hr. Ongoing monitoring: $200-400/mo.
See specialist rates
If you already run GTM for any other tracking (GA4, LinkedIn, TikTok), use GTM. Adding Meta Pixel to GTM is 30 minutes; maintaining two systems is forever. If GTM is not already installed and you only need Meta Pixel, PixelYourSite is the lower-overhead path — especially for WooCommerce stores where the plugin auto-handles e-commerce events.
Almost always because two install methods were used. The most common pairs: (1) PixelYourSite + a manual code snippet a previous agency left in functions.php; (2) PixelYourSite + GTM both firing the same pixel; (3) a caching plugin serving an old cached page that still has the legacy code. Audit Plugins, theme files, and GTM to find both — then disable one.
No — Conversions API is a Pro-tier feature. Free includes pixel install, basic event mapping, and Advanced Matching. If CAPI matters (it should, in 2026), either upgrade to Pro (~$100/year) or use Path B (GTM + server-side GTM via Stape).
You need a Consent Management Platform (CMP) plugin — Cookiebot, OneTrust, Iubenda, or Complianz. The CMP exposes a JavaScript variable indicating consent state. In PixelYourSite or GTM, gate the pixel firing on that variable. Without a proper CMP, you cannot legally fire the pixel for EU visitors and Meta will degrade your signal globally.
The most common cause is currency mismatch — WooCommerce sends the cart subtotal but PixelYourSite or your GTM tag is configured for total-with-tax. Audit the value variable: confirm it matches the displayed order total. Also check that the currency is passed (without it, Meta defaults to USD which breaks reports for non-USD stores).
Meta Ads
GTM is the right tool for a multi-platform tracking stack. One container, one consent layer, every pixel — Meta, GA4, LinkedIn, TikTok — coexisting cleanly. This walks through the Meta Pixel install inside GTM specifically.
Meta Ads
The browser pixel alone loses 20-30% of conversions on iOS. CAPI sends events from your server to Meta, recovering most of it. Three install paths: Shopify-native, server-side GTM, and direct API. We cover all three.
Meta Ads
Your pixel was working last month. Now Events Manager shows zero. Or it shows events but not the ones you need. This is the diagnostic sequence specialists run.
Meta Ads
DIY Meta Ads is the right call until it isn't. This is the honest framework: when the cost of self-managing exceeds the cost of hiring, and how to tell which side you're on right now.