
Why is my Meta Pixel firing twice?
When a Meta Pixel fires twice, the cause is almost always the event call, not the pixel. Two copies of the base code, a thank-you page that reloads, a double click, or two plugins sending the same Purchase all produce two requests to Meta. We tested the current pixel library (fbevents.js 2.9.433) in a real browser and found something that explains why these bugs survive audits: the library quietly stops a duplicate PageView, but it does not stop a duplicate Purchase.
So the page view count looks clean, the pixel helper shows one PageView, and the conversion column is still inflated. With Black Friday on November 27, this is the week to check, before Meta's bidding spends three weeks learning from doubled purchases.
How we tested it
We built small test pages, each reproducing one install mistake we see in tracking reviews, and loaded the real Meta Pixel script in headless Chromium. Every request to facebook.com/tr was captured and answered locally, so nothing reached Meta. We used made-up pixel IDs and read three parameters from each hit: id (the pixel), ev (the event name) and eid (the event ID used for deduplication).
That means these results describe what the browser sends. They don't show what Events Manager does with it afterwards. Where Meta's handling matters, we quote Meta's deduplication documentation, updated June 28, 2026.
What actually happens when the base code is installed twice?
This is the most common case: the pixel is in the theme and also added by a plugin, or hardcoded and also deployed as a Google Tag Manager tag. We tested both versions, including one where the second copy loads 2.5 seconds later, the way a GTM tag often does.
The results were the same each time:
- The console logs a warning:
[Meta Pixel] - Duplicate Pixel ID: <id>.The secondfbq('init')is ignored. - PageView went out once, not twice. The library keeps a list, per page load, of pixel IDs that have already sent a PageView, and drops a repeat for the same ID.
- Purchase went out twice. When both copies called
fbq('track','Purchase'), we captured two Purchase hits on the same pixel, 0 ms apart, both without an event ID.
That last point is the trap. Someone checks the pixel, sees a single PageView, and decides the install is fine. The protection only covers PageView. Every standard and custom event that both installations call gets sent twice.
If you see the Duplicate Pixel ID warning, assume your conversion events are doubled until you've proven otherwise.
What are the 6 causes of duplicate Meta Pixel events?
Here's what each install mistake did on the wire in our tests.
- Base code installed twice, same pixel ID. One PageView, two Purchases. The warning appears in the console.
- Two different pixel IDs on the page.
fbq('track','Lead')went to both pixels, one hit each. That's correct per pixel, but it becomes a double count when an old agency pixel is still connected to the same ad account or someone adds both datasets together in a report.fbq('trackSingle', '<id>', 'Contact')reached only the pixel it named. - Thank-you page reload. The Purchase fired again on reload, carrying the same
eid=order-1001both times. The browser has no memory of the first one. - Two plugins tracking the same order. One sent
eventID: 'order-1001', the other a plugin-generated ID. Two Purchases with different IDs, so even a perfect Conversions API setup can only match one of them. - Double click on a form button. Two Lead hits, 2 ms apart. Nothing in the pixel stops it.
- Hash links on long landing pages. Changing
location.hashproduced a second automatic PageView. A sales page with ten#sectionanchor links can turn one visit into many PageViews. That's mostly noise, but it distorts landing page view and cost per view numbers.
Does a single-page app send PageView twice?
The common advice for Next.js, React and other single-page apps is to "fire a PageView on every route change." Our tests suggest that advice is out of date, and following it alongside a popular "fix" can break your counts the other way.
The pixel already hooks history.pushState and history.replaceState. On each URL change it sends an automatic PageView, and it's allowed to bypass the one-PageView rule. In our test, two route changes produced three PageViews in total, one per URL. When we added the manual fbq('track','PageView') on each route change, the count was still three. The manual calls were dropped, because the automatic one had already gone out.
Then we tried the recipe many tutorials give for "duplicate PageViews in React": set fbq.disablePushState = true and send PageViews yourself. The result was one PageView for the whole session. The automatic ones were disabled, and the manual ones still hit the per-page-load rule and were dropped. Switching to fbq('trackCustom','PageView') didn't help.
On a single-page app, let the pixel handle route-change PageViews and don't set disablePushState. If you inherited a site with that flag, check Events Manager: page views per session that look suspiciously close to one are a sign the flag is working against you.
Doesn't Meta deduplicate these anyway?
Partly, and only in one direction. Meta's documentation describes deduplication between the browser pixel and the Conversions API: when the pixel's eventID and event match the server's event_id and event_name for the same pixel within 48 hours, Meta discards the later copy.
It doesn't promise to remove two browser events. For its fbp/external_id method, the page says it "does not deduplicate events when only using one event source," and that "if you send us two consecutive browser events with the same information, we do not discard either." The event ID section doesn't make a browser-to-browser promise either.
So the two Purchases from a duplicate install, the reload and the double click should all be treated as real events. If you run the Conversions API without matching event IDs, add a third copy from the server. Our Meta Conversions API setup guide covers getting the IDs to match.
How do you find a duplicate in five minutes?
You don't need a tag audit tool for the first pass.
- Watch the requests. Open DevTools, go to Network and filter by
facebook.com/tr. Complete a real test action, like a form submission or a test order. Count theev=Purchaseorev=Leadrows and read theireidvalues. - Read the console. The
Duplicate Pixel IDwarning tells you the base code is in two places. - List the pixels. Run
fbq.getState().pixels.map(p => p.id)in the console. Any ID you don't recognize is a pixel you're also feeding. - Pull a summary of every hit. Paste this into the console after the action. We checked it against our test pages, and it returned the duplicate Purchase pair exactly:
performance.getEntriesByType('resource')
.filter(e => e.name.includes('facebook.com/tr'))
.map(e => {
const u = new URL(e.name);
return [u.searchParams.get('id'), u.searchParams.get('ev'), u.searchParams.get('eid')];
});
It only sees requests sent as normal GET hits, which is how every event in our tests went out. Run it before leaving the page, because the list resets on navigation.
- Confirm in Events Manager. Use Test Events with the same action to see how Meta received it, including whether each event says browser, server, or both.
How do you fix each one?
Pick one installation path and delete the rest. The platform's native integration, a plugin, or GTM. Not two of them. On Shopify, check the theme files and Customer events (custom pixels), not just the app list. On WooCommerce, check the theme and every tracking plugin. When you remove a duplicate installation, check the events it was sending, not just the base code.
Guard one-time events with the order or submission ID. This is the reload fix we tested. On reload it sent the PageView again and no second Purchase:
var orderId = 'order-1001'; // from your order confirmation data
var key = 'meta_purchase_' + orderId;
if (!localStorage.getItem(key)) {
fbq('track', 'Purchase', {value: 49, currency: 'USD'}, {eventID: orderId});
localStorage.setItem(key, '1');
}
Use the same orderId as the event_id in your Conversions API call so the server copy deduplicates against it.
Fire Lead on success, not on click. Send the event when the form's submit response comes back successfully, and disable the button after the first click. That fixes the double click and stops failed submissions from counting as leads.
Use trackSingle when more than one pixel must stay. If a second pixel has a legitimate reason to be there, send each event to the pixel that should receive it instead of broadcasting with track.
Move one-time events server-side when you can. A purchase recorded from the order webhook is sent once per order, no matter how many times someone opens the thank-you page. That's the pattern we use with server-side GTM and in HYROS setups, where the order comes from the payment platform rather than the page. If you run HYROS, the same order-ID discipline helps with the problems covered in our HYROS no-source sales fix.
Why it matters more in November
Meta optimizes on the events you send. A campaign that "converts" twice per buyer reports half the real cost per purchase, so budgets scale on numbers that don't exist. Then the CRM or Stripe total doesn't match Ads Manager, and someone spends a week arguing about attribution when the cause is one extra script tag. If performance already feels unstable, our notes on recovering ROAS after Andromeda assume your event data is clean first.
The fix is usually an hour of work. Finding it takes longer, because the obvious check, the single PageView, says everything is fine.
Want us to look before Black Friday? We check the pixel, the Conversions API and the event IDs that link them, and send you the findings. Get a Free Automation Audit: you get your free initial audit report by email within 24 hours. If the fix belongs in a broader cleanup, that's the work our ads management and attribution team does every week.
