TikTok Events API for online stores
TikTok server-side tracking that shows TikTok all of your buyers.
TikTok server-side tracking through the Events API, with nothing to code: AxiTrace sends every order from your server to TikTok, with the TikTok click id and the buyer's hashed email and phone. Your TikTok pixel keeps running, and the two reports of one sale are merged into one.
- All 9 platforms on every plan
- Free up to 10,000 visits a month
- No credit card
- Event Purchase a standard TikTok event
- Order value value, currency from the order in your store
- Products bought contents ids, quantities and prices
- Order number order_id
- Event id event_id same as your pixel
- Ad click ttclid kept for 90 days
- Browser ttp from the _ttp cookie
- Email email SHA-256 hash
- Phone phone SHA-256 hash
- Customer id external_id SHA-256 hash
- Page view Pageview
- Product view ViewContent
- Add to cart AddToCart
- Checkout started InitiateCheckout
- Payment details AddPaymentInfo
- Order paid Purchase
The order leaves your server as TikTok's Purchase event, the one a sales campaign optimises for, with its value and the products bought.
An order that arrives without a TikTok click id is not lost: TikTok can match it on the hashed email and phone.
Every step before the purchase is sent too, under TikTok's standard event names, so a campaign can optimise for carts while purchases are still few.
What the TikTok pixel misses
A tap on a TikTok ad is a long way from the thank-you page.
The TikTok pixel reports a sale from your buyer's browser, on the page after checkout. A buyer who taps your ad in the app and pays later, or somewhere else, often never gets there with the pixel running.
-
up to 30%
of orders never reach the pixel
Ad blockers, Safari and consent banners cut the browser off before the purchase fires.
-
1 page
decides whether the purchase is reported
The thank-you page. A buyer who pays on the bank's or PayPal's site and closes the tab never opens it, so the pixel never fires.
-
2x
is what a sale counts for when pixel and server both report it
Without a shared event id the platform sees two purchases. The campaign looks twice as good and gets budget it never earned.
How it works with TikTok
Sent from your server, merged with your pixel.
Each order goes from your server to TikTok through the Events API, with ttclid and the hashed email and phone TikTok matches on. Your pixel stays in the store. AxiTrace fires its events itself, with the event_id of the server copy, so TikTok merges the pair into one sale.
- ttclid, kept for 90 days The click id TikTok adds to your ad links is stored with the visitor, so an order placed weeks after the tap still carries it.
- Email and phone as hashes Both leave as SHA-256 hashes, next to the _ttp browser id, a hashed customer id, the IP address and the browser.
- The same event_id on both sides ttq.track in the browser and the Events API call carry one event_id. Take out your own ttq.page() and ttq.track calls: TikTok would count those on top.
-
Browser pixel
no event id
event id
ord_10931 -
Server event
event id
ord_10931
2 purchases counted for one order
1 purchase counted for one order
Counted twice
Duplicate dropped
The platform cannot tell that both reports are one sale, so it counts two. ROAS in Ads Manager is inflated.
Both reports carry the same event id. The platform keeps one purchase, with the identifiers of both.
What changes
More purchases to learn from. Each one counted once.
TikTok looks for people like the ones who converted. It can only use the conversions it received and could tie to a person.
-
Ad delivery
A sales campaign with enough sales to learn
A campaign optimised for purchases needs purchases. Orders the pixel never reported now count, so TikTok has more real buyers to model its audience on.
-
Matching
Buyers recognised without a click id
A buyer who saw your ad on a phone and ordered on a laptop arrives without ttclid. The hashed email and phone let TikTok tie the order to that person anyway.
-
Reports
TikTok Ads Manager stops counting a sale twice
A purchase sent by the pixel and by the server is one conversion in TikTok Ads Manager, not two, so the cost per purchase you see there is not understated.
Test your deduplication
Setup
A pixel code and an access token, pasted once.
-
Install the app or plugin
Shopify, WooCommerce, PrestaShop, Shopware, Magento or OpenCart. Any other store uses one 11 KB script or a GTM tag.
-
Paste your pixel code and access token
Both come from TikTok Events Manager: the code of your pixel, in its settings under Web Events, and an Events API access token generated there. Test connection checks them with TikTok.
-
Test, then go live
Switch on Test mode with the code from the Test Events tab and watch each event arrive in Events Manager. Switch it off, and the events go to your live reports.
The facts
The TikTok Events API in AxiTrace, in short.
- Plan
-
All 9 platforms on every plan, Free included. A plan is sized by visits, not by events or by platforms.
See pricing - Events sent
-
Six funnel events, from page view to purchase, and Search, SubmitForm, Subscribe and StartTrial where your store has them. Any of them can be unticked on the connection page.
- Pageview
- ViewContent
- AddToCart
- InitiateCheckout
- AddPaymentInfo
- Purchase
- Matched on
-
The TikTok click id and browser id, hashed email and phone and a hashed customer id, with the IP address and the browser.
- ttclid
- ttp
- phone
- external_id
- Deduplication
-
One event_id on the pixel event and on the Events API event. A browser purchase still named CompletePayment is merged too: TikTok reads it as Purchase.
- Consent
-
An optional consent gate that reads Google Consent Mode v2 and TCF. A buyer who refused is never sent to an ad platform.
- Limits
-
A ttclid older than 90 days is left out, and an event with nothing TikTok could match is not sent. Only website events are sent, not app events.
- Your ad account
-
A TikTok sign-in imports your campaigns and spend, read only, and AxiTrace sets them against your orders per campaign. It never edits a campaign, a budget or a bid.
- Bidding on profit
-
On Business and Custom, the purchase can carry the profit of the order as its value, so TikTok's value-based bidding works on profit.
How profit bidding works - On Shopify
-
TikTok gets the purchase from the server alone. The optional Custom Pixel of the Meta Pixel Bridge fires your TikTok pixel as well, for page views, product views, carts and checkouts.
Read the Meta Pixel Bridge guide - Your data
-
Stored in the EU, on Google Cloud in Warsaw, under a data processing agreement.
Frequently asked questions
Something else on your mind? Ask us directly
What is the TikTok Events API?
The Events API is TikTok's way of receiving events from a server instead of from the buyer's browser. The TikTok pixel can be stopped by an ad blocker, or never fire because the buyer closed the tab before the thank-you page, and up to 30% of orders are lost that way. An event sent from your server arrives anyway, and it carries what TikTok matches on: ttclid, a hashed email and a hashed phone.
Why does my TikTok pixel undercount conversions?
Because it runs in the buyer's browser. An ad blocker stops it from loading, and a buyer who pays on the bank's site and never returns to the thank-you page never triggers it. A buyer who comes back on another device arrives without the TikTok click id. Your store still records every one of those orders, and AxiTrace sends them to TikTok from your server.
Does AxiTrace deduplicate TikTok pixel and Events API events?
Yes. AxiTrace fires the pixel event in the browser and sends the Events API event from the server with the same event_id, so TikTok counts one conversion. This also holds for the purchase: the browser copy goes out under the older name CompletePayment, which TikTok reads as Purchase. You can check a pair of events with the free deduplication tester.
Do I keep my TikTok pixel?
Yes. Keep the pixel's base code with ttq.load on the store, and remove ttq.page() and any ttq.track calls of your own or of a second pixel plugin: AxiTrace fires those events itself, with the event_id it also sends from the server, and copies without that id would be counted twice. On Shopify the purchase is sent from the server only.
Do I need the TikTok Events API Gateway or server-side GTM?
No. Both are ways to get events to the Events API: a gateway relays the events of your pixel, a server container runs tags you configure. AxiTrace records each order in your store and sends it to the Events API itself, with the event_id your pixel also uses. There is no gateway to subscribe to, no container to host and no tag to map, and the same install sends the order to Meta, Google and the other platforms you connect.
Does TikTok server-side tracking work on Shopify and WooCommerce?
Yes, and on Shopware, PrestaShop, Magento and OpenCart too. Install the AxiTrace app or plugin for your store, paste the pixel code and the access token, and every order goes to TikTok from the server. On Shopify the purchase is sent from the server only, and the optional Custom Pixel of the Meta Pixel Bridge fires your TikTok pixel for the steps before it.
Where do I find my TikTok pixel code and access token?
Both are in TikTok Events Manager. The pixel code is in the settings of your pixel, under Web Events, and the Events API access token is generated in the same place. Paste both into AxiTrace and press Test connection. To see the events before they reach your reports, switch on Test mode with the code from the Test Events tab.
Does AxiTrace change anything in my TikTok ad account?
No. The Events API connection only sends events to your pixel. If you also sign in to TikTok Ads, AxiTrace reads your campaigns and spend to show them next to your orders, and never edits a campaign, a budget or a bid. On Business and Custom you can choose to send the profit of each order as the purchase value. That changes the value TikTok receives, nothing in the account.
Which plan do I need?
All 9 destinations are on every plan, including the Free plan with 10,000 visits a month and no credit card. Each eligible AxiTrace session counts as one visit, however many events or platform deliveries it generates, so the plan you need depends on your traffic, not on how many platforms you connect.
Let TikTok count the sales its pixel never saw.
Free up to 10,000 visits a month. Growth, Pro and Business are free for 14 days, with no card and no automatic charge.
An agency, or more than 3M visits a month? Talk to us
- Data stored in the EU
- GDPR, with a DPA
- On the Shopify App Store
- Plugin on WordPress.org
- In ChatGPT and Claude
Opening the demo...
The demo could not be opened. Try again in a moment.
Start Free