How to use the Ad Pixel Event Code Generator
- Choose the platform: Meta Pixel, Meta Conversions API (server), TikTok, LinkedIn or Pinterest.
- Pick a standard event — or a custom one — and fill in value, currency and other parameters; shopping events get an Items list.
- Add an event ID if you also send the event from your server, so the platform counts it once.
- Choose when it fires — right away, on a click or on a form submit — and copy the code. For the Conversions API, copy the server request and keep the token secret.
Standard events per platform
- Meta Pixel —
fbq('track', 'Lead'),Purchase,AddToCart,CompleteRegistrationand the other standard events Meta optimizes ads for, withvalue,currency,content_idsandcontents; anything else istrackCustom. The event ID goes in the fourth argument aseventID. - Meta Conversions API — the same event sent from your server to the Graph API, with
user_datahashed with SHA-256 (email lowercased, phone digits only), the visitor’s IP, user agent and_fbp/_fbccookies. The email you type here is hashed in your browser to show the format. - TikTok Pixel —
ttq.track('CompletePayment'),SubmitForm,AddToCart… withcontents,valueandcurrency; the event ID is the third argument. - LinkedIn Insight Tag —
lintrk('track', { conversion_id })for a conversion you created in Campaign Manager. - Pinterest Tag —
pintrk('track', 'checkout'),lead,signup,addtocart… withline_itemsandevent_idin the data.
All of them need the platform’s base code on the page first, and — in the EU and UK — the visitor’s consent; load them through the Cookie Consent Banner Generator. Track the same action in Google Analytics with the GA4 Event Code Generator, or tag every button at once with the Event Tracking Script.
Also searched as: pixel event code generator, meta pixel event code, facebook pixel event generator, meta conversions api example, tiktok pixel event code, linkedin conversion tracking code, pinterest tag event code, fbq track purchase.
Tools that pair well with the Ad Pixel Event Code Generator
- Consent Mode Checker — Check a site’s cookie consent the way a regulator or an ad platform would.
- UTM Builder — Add utm_source, utm_medium, utm_campaign and friends to any link, see which GA4 channel the visit will land in, and tag a whole list of URLs at once.
- Google Tag Snippet Generator — Enter your GA4 measurement ID, Google Ads ID or Tag Manager container ID and get install code that is ready to paste — with Consent Mode v2 defaults, cross-domain linking, debug mode, manual page views and cookie settings switched on only when you need them.
- GTM Snippet Generator — Enter your GTM container ID and get the Google Tag Manager install code for the <head> and <body>, with Consent Mode v2 defaults placed before the container so every tag inside it waits for consent.