Magento 2 TikTok Pixel Extension

View Demo

Add the TikTok pixel to your Magento 2 store and send the same events from your server through the TikTok Events API, so your TikTok ads optimize on complete data.

The extension tracks 8 standard TikTok events, from product views to placed orders, merges browser and server copies by one event ID, and sends the same events and order totals as our GA4, Facebook Pixel and Mixpanel extensions.

  • Send 8 standard TikTok events from every store page.
  • Send the same events from your server through the Events API.
  • Keep tracking orders when an ad blocker stops the pixel.
  • Send order values with or without tax.
Marketplace Approved
Hyvä
Magento Cloud
WCAG
Mage-OS
Compatible with:
Community:
2.3.* - 2.4.9
Enterprise:
2.3.* - 2.4.9
Problem

The TikTok pixel runs in the shopper's browser, so ad blockers and dropped connections stop part of your events. TikTok then optimizes your ads on incomplete data and reports fewer orders than your store actually took.

Solution

The extension adds the TikTok pixel to every page without theme edits and sends 8 standard TikTok events twice: from the browser and from your server through the TikTok Events API. Both copies carry one event ID, so TikTok counts each event once.

Main features of the Magento 2 TikTok Pixel extension

  • TikTok pixel on every store page, no theme code to edit
  • 8 standard TikTok events, from product views to placed orders
  • Events API: the same events sent from your server
  • Browser and server events deduplicated by one event ID
  • Advanced matching with hashed email and phone
  • Order value with or without tax, per store view
  • Same events and settings as our GA4, Facebook Pixel and Mixpanel extensions
  • Works with Luma, Hyvä and Hyvä Checkout, Magento Open Source and Adobe Commerce

Events API: events that reach TikTok when the pixel can't

The pixel alone depends on the browser. When an ad blocker or a weak connection stops it, the order still happens, but TikTok never hears about it, and your campaigns look worse than they are.

Every event goes from the browser and from your server

Once you add an Events API access token, the extension sends each event the pixel tracks from your server as well. If an ad blocker stops the pixel, the server copy still reaches TikTok.

One event ID, so nothing is counted twice

The browser event and its server copy share the same event ID. TikTok uses it to merge the pair, so an order seen by both the pixel and the Events API appears in Events Manager once.

Advanced matching helps TikTok recognize the buyer

Events carry the customer's email and phone number, normalized and hashed with SHA-256 before they leave your store, plus the TikTok click ID, the TikTok cookie, IP address and user agent. TikTok uses them to match a visit to a TikTok account and attribute the order to the right ad.

Which events the extension sends to TikTok

These are TikTok's standard events, under the same names you'll see in TikTok Events Manager. Product, cart, checkout and order events carry the product IDs, names, categories, prices, quantities, order value and currency; a configurable product or a product list is sent as a product group.

  • View content ViewContent
  • Search Search
  • Add to cart AddToCart
  • Add to wishlist AddToWishlist
  • Start checkout InitiateCheckout
  • Add payment info AddPaymentInfo
  • Place an order PlaceAnOrder
  • Customer registration CompleteRegistration

With this data, you can build custom and lookalike audiences in TikTok Ads Manager, bring back shoppers who viewed products or left the cart, and let TikTok optimize delivery for placed orders rather than clicks.

Order value with or without tax

Analytics tools such as GA4 expect prices without tax, but TikTok often works better with the amount the shopper actually paid. Turn on "Include tax in event value" for a store view, and checkout and order events send TikTok tax-inclusive prices while GA4 keeps receiving them without tax. Shipping is never included.

Check the events before you spend on ads

A debug toolbar on the storefront lists every event as it fires, with the exact data sent to TikTok and a separate tab for each tracker. TikTok's own Pixel Helper and Events Manager show the same events on their side.

Debug toolbar on a category page showing the AddToCart event data sent to TikTok

One data layer for all your ad pixels

The extension runs on the Mirasvit tracking layer, which is included in the package. It's the same layer our GA4 and Google Tag Manager extension, Facebook Pixel and Mixpanel use. If you add any of them, TikTok, Google and Meta receive the same events, products and order totals, and you set up the product ID (SKU or ID), attribute mapping, prices in the store currency, event exclusions and debugging in one place. Product and category views by search engine bots aren't tracked, and you can send custom events on clicks by adding a data attribute to any element.

How to connect TikTok Pixel to Magento 2

1. Connect the pixel. Paste your Pixel ID and the pixel code from TikTok Events Manager into the extension settings. You can use a different pixel for each website or store view.

2. Turn on the Events API. Generate an access token in your pixel settings in Events Manager and paste it in, so the server events start.

3. Check the events. Open the debug toolbar on your storefront, TikTok Pixel Helper or the Test Events tool in Events Manager.

The extension works with Luma and Hyvä themes (including Hyvä Checkout) without a separate compatibility package, with Content Security Policy enabled, and with Adobe Commerce B2B purchase orders. See the setup guide for details.

TikTok Pixel Helper showing PageView and ViewContent events with product parameters from a Magento category page
No hidden fees
Our developers install the extension on your store and configure it for your setup, free of charge.
Lifetime access to source code
Access to free support and updates for 1 year
Updates and support prolongation - $42

Pay today $69 for the first year.

Then $42 for updates and support services per year.

Cancel anytime.

30 days money back guarantee
See it in action!
Pick a quick tutorial to learn about various aspects of this extension
Customer Reviews 0
Earn points for your review about this extension modules. $1 = 10 points
Write Your Own Review

check-circle You submitted your review for moderation.

Manual & Support
Need more help?

Save time by starting your support request online and we'll connect you to an expert.

Frequently asked questions
chevron-down chevron-right

Does the extension send events server-side through the TikTok Events API?

Yes. Add an Events API access token in the extension settings, and every event the pixel tracks is also sent from your server to the TikTok Events API. The browser and server copies share one event ID, so TikTok counts each event once.

chevron-down chevron-right

How is the TikTok Pixel different from the Events API?

Both send the same shopping events to TikTok. The pixel sends them from the shopper's browser, so ad blockers and dropped connections can stop it. The Events API sends them from your server, so those events still reach TikTok. Using both gives TikTok the most complete data.

chevron-down chevron-right

How do I connect TikTok Pixel to Magento 2?

Paste your Pixel ID and pixel code from TikTok Events Manager into the extension settings, then generate an access token in your pixel settings and paste it in to turn on the Events API. Check the events in the storefront debug toolbar or TikTok Pixel Helper. The setup guide walks through each step.

chevron-down chevron-right

What is a TikTok Pixel and where do I find it?

It's a JavaScript snippet added to every page of your store that sends shopping events and basic visitor data to TikTok.

To find your Pixel ID and code, go to TikTok Ads Manager: Tools > Events Manager > Data Sources and select your pixel.

chevron-down chevron-right

Does it work with Hyvä and Hyvä Checkout?

Yes. Hyvä themes and Hyvä Checkout are supported out of the box, with no separate compatibility package to install. The extension also works with Luma and with Content Security Policy enabled.

chevron-down chevron-right

Do I need to buy the Tag Manager extension separately?

No. The extension runs on the Mirasvit tracking layer, which is installed with it as part of the package. If you also use our GA4 and Google Tag Manager, Facebook Pixel or Mixpanel extensions, they share the same events and settings.

chevron-down chevron-right

Can TikTok receive order values with tax?

Yes. Turn on Include tax in event value for a store view, and checkout and order events send TikTok item prices and order values with tax, the amount the shopper actually paid. GA4 keeps receiving prices without tax. Shipping is never included. The setting is off by default.

Changelog
Version 1.2.1Sep 21, 2026
New "Include tax in event value" setting (TikTok pixel > Include tax in event value, per store view, off by default). When enabled, item prices and the event value sent to TikTok include tax — the amount the shopper actually pays — instead of the tax-exclusive amounts used by GA4. Shipping is never included. Covers begin checkout, purchase and add payment info events, in both the pixel and the Events API
TikTok pixel not detected on Hyva Checkout — the injected pixel script now reuses the CSP nonce already present on the page instead of generating a fresh one, which was absent from the framework's CSP header and blocked the script under CSP restrict mode
Server-side events that arrived without an event ID were still sent to the TikTok Events API as an empty request, producing a PHP warning and a rejected call — such events are now skipped
Customer phone numbers could be silently dropped from server-side events on long or unusual input, lowering TikTok's match rate — the number is now kept and sent as entered
Version 1.2.0Jun 10, 2026
Event tracking is now delivered through the Tag Manager (Mirasvit_Tm) shared data layer — the module's own AJAX cart plugin, payment controller, frontend routes and debug toolbar were removed
Debug Mode and logging unified with the Tag Manager module (shared debug toolbar)
Hyva theme is supported out of the box — the separate mirasvit/module-tiktok-pixel-hyva compatibility extension is no longer needed and must be removed
Requires mirasvit/module-tm 1.1.0 or newer
Version 1.1.4May 21, 2026
Optimized add-to-cart event tracking
Version 1.1.3May 19, 2026
Localized to 15 core e-commerce locales (ar, cs, de, es, fr, it, ja, nl, pl, pt-BR, pt-PT, sv, tr, uk, zh-Hans)
Version 1.1.2Dec 10, 2025
Undefined array key "currency" in PixelConverter
Reasons to choose Mirasvit
Client focusing and satisfaction

These are our primary. A major portion of our new clients come from referrals from our existing clients. Our professional team of developers, marketers and support staff have invested the best knowledge and experience in the field into our work, so you know you can come back to us again and again.

Remarkable support

One year free and high quality support. We go to great lengths to provide maximum satisfaction with every module you have purchased in our store. By helping you with installation, configuration, answering your every question, we do all our best to eliminate any possible problems.

Risk-free Investment

30-days money back guarantee. If you are not satisfied with our TikTok Pixel for Magento 2 performance for any reason, we provide a full refund.

Constant improvements and upgrades

We constantly add new features to all our modules, and are always interested in hearing your opinion and implementing your suggested features in our future developments.

Comprehensive Documentation

We provide an expanded user guide for every aspect of our Magento TikTok Events API, so you can find answers for all your burning questions.

Unencrypted source code of our products

You can customize TikTok Pixel Magento 2 extension according to your needs and requirements.

Usability and Performance

The Module is easy to install and upgrade, just follow our step-by-step user guide. Additionally, the extension is ready to use with the Hyvä theme.

Ready for Magento Cloud

No core modifications. The TikTok Pixel Magento 2 extension has been tested in a Magento Cloud environment and is fully compatible with it.

Loading...