On this page
Conversions API
Conversions API sends your Matomo goals and ecommerce orders server-side to Google Ads, Meta, LinkedIn, X, Microsoft Advertising and now also ChatGPT Ads and TikTok: with consent per platform, automatic click attribution and close to real time.
Plugin page · from €59/month net
Overview
Conversions API sends the conversions Matomo already records (goals and ecommerce orders) server-side to Google Ads, Meta, LinkedIn, X, Microsoft Advertising, ChatGPT Ads and TikTok Ads, or to any address of your choice via webhook. You need no ad pixels on your website, and ad blockers or browser restrictions no longer distort your campaign figures.
New: ChatGPT Ads (OpenAI) as a destination, and for Microsoft Advertising the Conversions API that Microsoft opened to all accounts on 28 October 2026.
How it works
Per website you set up one or more destinations and define which Matomo goals are sent as which conversion. Matomo records the conversion as usual; a background job sends it within a minute with the recommended cron job, for Google with an adjustable delay. Per destination you choose the attribution: send every conversion, like a pixel, or only after a contact via this source in the time window, only if it was the last or only if it was the first contact. This way two affiliate partners are not paid for the same order.
- Google Ads: Data Manager API, authentication via service account, clicks via gclid, gbraid and wbraid, processing status in the send log.
- Meta: Conversions API with event names such as Purchase or Lead, fbclid and the Meta cookies _fbp/_fbc.
- LinkedIn: Conversions API with conversion rules, clicks via li_fat_id.
- X (Twitter): web conversions of the X Ads API, sign-in with a pixel token or OAuth, clicks via twclid.
- Microsoft Advertising (Bing): UET Conversions API with the UET tag's token, clicks via msclkid. The plugin also reads Microsoft UET Consent Mode.
- ChatGPT Ads (OpenAI): pixel ID and key from OpenAI Ads Manager; orders as order_created, enquiries as lead_created; click ID oppref from the landing page and, with consent, from the OpenAI pixel's cookie.
- TikTok Ads: Events API with the pixel code and an access token from TikTok Events Manager; standard events such as Purchase or Lead; clicks via ttclid and, with consent, the TikTok pixel's cookie.
- Webhook / Postback: sends every conversion to an address you choose, for example an affiliate network, a CRM, your own endpoint or automation services such as n8n, Zapier and Make that trigger further steps from it: POST with JSON or form, or GET, with placeholders such as order ID, value or click ID. Every webhook has its own consent key and click ID parameters, and requests can be signed.
Consent first
Only what the visitor consented to is sent, per platform. Your consent banner passes the decision via Matomo Tag Manager, Google Consent Mode or the JavaScript API. If the visitor answers only after the conversion, for example for a goal reached on page view, the conversion waits up to 24 hours for the decision; a withdrawal stops everything not sent yet. Optionally your website passes customer data such as the email address; Matomo normalises and hashes it per platform, and plain text is never stored.
Full control
The send log shows every transfer with its status, the platforms' error messages and "Retry". Authentication errors pause a destination automatically, and Matomo e-mails the super users and the website's administrators when a destination is paused, has only reported errors for 24 hours or is switched off. A destination can be copied to other websites, goals matched by name. Matomo's raw data deletion and GDPR tools cover the plugin's data. You find the plugin under Administration → Websites → Conversions API and in the reports under Goals → Conversions API, also in Matomo's dark mode.
Use cases
- New: ChatGPT Ads and Microsoft's Conversions API: Conversions API now also sends your conversions to ChatGPT Ads, OpenAI's ad platform, through OpenAI's Conversions API. For Microsoft Advertising the plugin uses the Conversions API that Microsoft opened to all ad accounts on 28 October 2026, and now also sends the page URL of every conversion.
- No pixels, no gaps: Matomo already records the conversion. Conversions API sends it straight to the ad platforms, so ad blockers and browser restrictions no longer swallow anything, and you need no extra tags on your website.
- Clicks attributed automatically: The plugin detects ad clicks from Google (gclid, gbraid, wbraid), Meta (fbclid), LinkedIn (li_fat_id), X (twclid), Microsoft (msclkid), ChatGPT Ads (oppref) and TikTok (ttclid) and attributes later conversions, even after a login and across visits within your lookback window.
- No double commission: Per destination you decide who gets a conversion: every platform, only after a contact via this source, only for the last or only for the first contact. This way two affiliate partners are not paid for the same order, and the send log shows why.
- Filter per destination: With Matomo's segment builder you decide which visits a destination receives, e.g. only one ad group or one country. Agencies route the conversions of one website to several ad accounts this way.
- Consent per platform: Only what the visitor consented to is sent. The signal comes from your consent banner via Matomo Tag Manager, Google Consent Mode or the JavaScript API. Per website you choose the mode "Strict" or "External". If the visitor answers only after the conversion, it waits up to 24 hours for the decision.
- Lean on data: Customer data is normalised and hashed in Matomo; plain text is never stored. IP address, user agent and hashes are deleted after sending, at the latest after 7 days, click IDs after 90 days.
- Every transfer traceable: The send log shows what went to which platform and when, with the platforms' error messages, "Retry" and, for Google, the processing status. Expired access is detected and reported.
Setup step by step
How to install the plugin is described under Installing plugins. The Conversions API needs a self-hosted Matomo 6 or Matomo 5 with PHP 8.1 or newer, also on the command line. You set it up per website under Administration → Websites → Conversions API or in the reports under Goals → Conversions API. Both are available to administrators of the website.
1. Add the cron job
A background job sends the conversions. Run it every minute, otherwise Matomo sends only once per hour. The plugin page shows the exact line under Setup:
* * * * * php /path/to/matomo/console feinwerkconversionsapi:dispatch > /dev/null 2>&1
Set up the cron job as the web server user (e.g. with crontab -u www-data -e), not as root: the background job also updates matomo.js. With several Matomo servers each one has its own matomo.js; then update it on each of them with ./console custom-piwik-js:update.
If several PHP versions are installed, use the full path of the PHP 8 binary. If the job has not run for more than 15 minutes, the plugin page shows a notice.
2. Add a destination
Choose Google Ads, Meta (Facebook/Instagram), LinkedIn, X (Twitter), Microsoft Advertising (Bing), ChatGPT Ads (OpenAI), TikTok Ads or Webhook / Postback and enter the access. Credentials are stored encrypted. How to get the credentials and IDs is explained step by step under Credentials per platform.
- Meta: Events Manager → data source → Settings → Conversions API → Generate access token, plus the dataset (pixel) ID. The target is an event name such as
PurchaseorLead. - Google Ads: In a Google Cloud project, enable the Data Manager API, create a service account with a JSON key and add its email address as a user in Google Ads, plus the customer ID of the account with the conversion action. The target is the ID of a conversion action of type Import from clicks.
- LinkedIn: Campaign Manager → Signals Manager → Direct API → create an access token, plus the ad account ID. The target is the ID of a conversion rule of type Conversions API.
- X (Twitter): Look up the pixel ID in X Events Manager. Sign in with the pixel token from Events Manager or with the four OAuth keys of an app from the X Developer Portal; if both are filled in, the pixel token is used. The target is the event ID of the conversion event, such as
tw-abc12-def34. - Microsoft Advertising: Open the UET tag, choose Use Conversions API and create the token, plus the UET tag ID. The target is the event name that matches the conversion goal in Microsoft Advertising, such as
purchaseorlead. The Conversions API has been open to all ad accounts since 28 October 2026; the plugin also sends the page URL of the conversion. - ChatGPT Ads (OpenAI): In OpenAI Ads Manager under Conversions, create a pixel if there is none yet, and a key for the Conversions API. OpenAI must have enabled your ad account for it. Plus the pixel ID. The target is an OpenAI event type, e.g.
order_createdfor orders,lead_createdfor enquiries, alsoregistration_completed,appointment_scheduledorsubscription_created, or a name of your own of lowercase letters, digits,_and-, which the plugin sends as a custom event. The plugin sends the value in the currency's smallest unit. It recognises clicks from ChatGPT ads by the landing page parameteroppref; with consent it also reads the OpenAI pixel's cookie__oppref. OpenAI decides in which countries ChatGPT ads run. - TikTok Ads: In TikTok Events Manager, open the pixel and click "Generate Access Token" under Settings; the token works for the pixels of the same ad account. Plus the pixel code. The target is a standard event (
Purchasefor orders,Leadfor enquiries, also e.g.CompleteRegistration,Subscribe,Schedule) or a name of your own of letters, digits and_; TikTok does not optimise campaigns for custom events. The plugin recognises clicks byttclidin the landing page URL and, with consent, by the TikTok pixel'sttclidcookie. With consent it also sends the TikTok pixel's_ttpcookie, which TikTok uses to match conversions to its ads. With a test event code the events appear under Test Events during setup, and "Test connection" sends a test event. - Webhook / Postback: for affiliate networks, CRMs, your own endpoints and automation services such as n8n, Zapier or Make (see Examples). Enter the address under Webhook URL (https only) and choose POST with JSON or form, or GET, under Method. Placeholders such as
{{order_id}},{{value}}or{{click_id}}are allowed in the path, in the parameters and in the body template. Under Consent key you set the name under which your website passes the consent for this webhook, for exampleawin, and under Click ID parameters up to five URL parameters of the network, for exampleawc. With a Signing secret the plugin signs every request. For webhooks, Test connection sends nothing; it shows the request for a sample conversion. Send test request in the list of destinations sends this sample conversion for real after a confirmation and shows the receiver's answer; an affiliate network may count it as a real conversion.
Under Goals to send you assign Matomo goals and the ecommerce order to a target of the platform and choose the value: revenue of the conversion, a fixed value or none. Test connection checks the access.
Attribution
Per destination, the attribution decides when a conversion goes to it:
| Attribution | Sent when … |
|---|---|
| Send every conversion (default) | the visitor consented; the platform attributes it itself |
| Only after a contact via this source in the time window | there was at least one contact via this source in the window |
| Only if this source was the last contact | the last contact before the conversion came via this source |
| Only if this source was the first contact | the first contact in the window came via this source |
- Contacts are the visitor's visits in Matomo that did not come directly (search engine, website, campaign, social network or a visit with a click ID). Direct visits without a click ID do not count. With a User ID, visits on other devices count too.
- A destination's source: its click IDs in the landing page URL (
gclid,gbraid,wbraid,fbclid,li_fat_id,twclid,msclkid,oppref,ttclid, for webhooks their click ID parameters), plus optional further markers: entries with a dot are domains of the page the visitor came from (partner-blog.dealso matcheswww.partner-blog.de,pinterest.commatches visits from Pinterest), entries without a dot campaign sources (utm_source,mtm_source, e.g.awin). A network's redirects (such as awin1.com) usually do not appear as the origin; use the click ID or the campaign source for them. Matomo stores campaign sources only with the plugin Marketing Campaigns Reporting. - Time window: 1 to 90 days before the conversion (default 30), or 0 for only the visit with the conversion. The window also applies to the click ID the plugin sends along.
- Example: Monday a click via Awin, Wednesday a click on a Meta ad, Friday a direct visit with an order. With "last contact" only Meta gets the conversion, not Awin; with "contact in the time window" both; with "first contact" only Awin. This way two partners are not paid for the same order.
- Recommendation: ad platforms attribute conversions themselves and optimise with all conversions, keep "Send every conversion" for them. For affiliate networks via webhooks, "last contact" is recommended.
- Send log: conversions not sent appear there as "Not attributed" with the reason, e.g. "Last contact: Meta (click), 2 days before the conversion".
- Limits: the attribution only sees visits that Matomo still keeps as raw data (setting "Delete old raw data"); without cookies Matomo usually does not know earlier visits. Matomo stores the origin of a visit's first page view.
- Webhooks: for a new webhook the plugin chooses "contact in the time window" as soon as you enter click ID parameters, because affiliate networks usually cannot attribute a conversion without a click ID. Without click ID parameters it stays at every conversion, for receivers such as a CRM, n8n, Zapier or Make. A rule other than "every conversion" needs click ID parameters or further markers on a webhook.
- Before version 5.3.0 the option was called "Only send conversions after a click on this platform". Where it was switched on, it now reads "Only after a contact via this source in the time window".
Filter
Each destination can have a filter: it then receives only conversions whose visit matches it. You set it up in the destination form under "Filter (optional)" with Matomo's segment builder, using any property of the visit, such as source, campaign, device, country, new or returning visitor, user ID or visit-scope custom dimensions. "Copy a saved segment" copies the condition of a segment from the segment editor once; later changes to the segment do not change the filter. Without a filter every conversion goes to the destination, as before.
- Example: an agency advertises the sections of one website from two Google Ads accounts. Two Google destinations, one per account, with the filters "ad group is XYZ" and "ad group is ABC", send each conversion to the right account. Matomo knows the ad group only with the Marketing Campaigns Reporting plugin and when the ad passes it in its address, e.g. with
mtm_group={adgroupid}in the Google Ads tracking template. - The visit of the conversion is checked. A visitor who came through an ad earlier and buys directly later does not match "campaign is …". Earlier contacts are covered by the attribution. The filter is meant for properties that are fixed when the visit starts.
- Send log: conversions that were not sent appear there with "Does not match the destination's filter". If the visit is no longer stored or the filter is no longer valid (e.g. because a dimension was deleted), the log says so; nothing is sent then. The list of destinations shows an invalid filter as "Filter invalid".
- Limits: properties of the visit only, no single page views or events. Conditions on addresses (URLs) can be slower on large instances. When copying to other websites, the filter is only taken over where it is valid.
3. Connect your website
Matomo records the conversion itself as usual. Your website additionally passes the visitor's consent and, on the order confirmation page, the customer data, most easily through Matomo Tag Manager:
var _mtm = window._mtm = window._mtm || [];
_mtm.push({event: 'fwcapi_consent',
fwcapi_consent: {google: consent.google, meta: consent.meta, linkedin: consent.linkedin,
x: consent.x, microsoft: consent.microsoft}});
consent stands for the visitor's actual decision from your consent banner, never true for everyone. For a webhook, pass the decision under its consent key in the same entry, for example awin: consent.awin. The plugin page shows the code with the keys of all destinations of the website under Setup.
On the order confirmation page, before Matomo tracks the order:
_mtm.push({event: 'purchase', ecommerce: {transaction_id: 'A-4711'},
user_data: {email: 'jane@example.org', phone_number: '+4915112345678'}});
If your website uses Google Tag Manager or Google Consent Mode, the plugin reads those entries as well, and Microsoft UET Consent Mode (uetq.push('consent', …)) as the decision for Microsoft. Without a tag manager there is the JavaScript API (_paq.push(['FeinwerkConversionsApi::setConsent', consent])), for server-side tracking the parameters fwcapi_consent, fwcapi_ud and fwcapi_eid. The plugin page shows the right code under Setup. All signals and rules are under Consent in detail.
4. Check the first data
The Send log shows per period what was captured, scheduled, sent or skipped, and below every conversion with its status, attempts and the platform's error message. Retry sends a failed conversion again. For Google, the table of requests also shows the processing status at Google.
Credentials per platform
How to get the credentials and IDs a destination needs.
Google Ads
The plugin signs in to Google with a service account and sends through the Data Manager API; no Google Ads API developer token is needed. Whoever sets it up needs the Owner role in the Google Cloud project (the person who creates the project has it) and admin access to the Google Ads account, for agencies to the manager account (MCC).
- Project: In the Google Cloud console, create a project or pick an existing one.
- Enable the API: APIs & Services → Library → Data Manager API → Enable.
- Service account: IAM & Admin → Service Accounts → Create service account (e.g.
matomo-conversions) and grant it the role Service Usage Consumer (roles/serviceusage.serviceUsageConsumer) in the project. Note the service account's email address (…@<project-id>.iam.gserviceaccount.com). - JSON key: On the service account, Keys → Add key → Create new key → JSON. The file is downloaded only once; treat it like a password. If Google reports Key creation is not allowed on this service account, an organization policy forbids keys (the default for organizations created since May 2024). An organization policy administrator (
roles/orgpolicy.policyAdmin) lifts it for this project only: IAM & Admin → Organization policies → select the project →iam.disableServiceAccountKeyCreation(andiam.managed.disableServiceAccountKeyCreation, if present) → Manage policy → Override parent's policy → Add a rule → Enforcement off → Set policy. The change takes effect within 15 minutes. - Access in Google Ads: In the manager account or directly in the account with the conversion action: Admin → Access and security → Users → + → the service account's email address, access level Standard. No invitation has to be accepted.
- Conversion action: type Import, Conversions from clicks. Its ID is shown as
ctId=…in the address bar after clicking the action. Google accepts brand new actions only after a few hours. - Customer data: Goals → Conversions → Settings: agree to the customer data terms and turn on enhanced conversions for leads, in the account that owns the conversion action (with cross-account conversion tracking in the manager account). Only then does Google use hashed email addresses and phone numbers.
- In Matomo: Add a Google Ads destination and paste the full content of the JSON file. Google Ads customer ID = the account that owns the conversion action. Manager account ID = the manager account from step 5 if the service account was added only there and the action belongs to a client account; otherwise leave it empty. Target = the
ctId. Then Test connection.
Common errors from Google:
SERVICE_DISABLEDor Data Manager API has not been used in project …: step 2 is missing.PERMISSION_DENIED: the service account is not a user of the account (step 5), or the customer ID or manager account ID does not match. Google also reports a conversion action that does not exist in this account this way.INVALID_CONVERSION_ACTION_TYPE: the action is not an import action for clicks.CONVERSION_ACTION_TOO_RECENTLY_CREATED: the action is too new; wait a few hours, then send again.DESTINATION_ACCOUNT_ENHANCED_CONVERSIONS_TERMS_NOT_SIGNED: step 7 is missing.invalid_grantwhen signing in: the key was deleted, or the Matomo server's clock is wrong.
Changing the key: create a new key, enter it in Matomo and save, then delete the old one in the Cloud console.
Conversion action of type Website (beta at Google): If the Google tag already runs on the website, the plugin can supplement the existing website action instead of using an import action of its own. Google then recovers conversions the tag misses and counts a conversion reported by both tag and plugin only once.
- Only for website actions set up manually with the Google tag or Google Tag Manager; not for actions imported from Google Analytics or URL-based actions.
- In Google Ads: Goals → Conversions → Summary → open the website action → Details → Data source → Connect another data source. If the option is missing, the beta is not yet available for the account.
- The tag must send a transaction ID; Google matches tag and plugin by it. In the plugin, choose Order ID, otherwise the event ID passed by the website under Deduplication with an existing pixel; for goals without an order, the website passes the plugin the same ID as the tag (
setEventId). - The target in the plugin is the ID of this action (
ctId). Google recommends sending within 24 hours of the tag event; the preset send delay of 6 hours fits. - The plugin's value permanently replaces the tag's value; currency and units must match the tag.
- Google matches only within the same action: do not report the same conversions to a second action in the same campaigns as well, or they count twice.
- During the first 14 days the additional conversions appear in reports but are not yet used for bidding, and values are not yet replaced.
Meta
The access token is generated by someone with developer privileges in the business portfolio (Business Manager); without them the link is missing. No app review by Meta is needed.
- Events Manager → Data sources → select the website's pixel (dataset). The dataset ID under Settings is the pixel ID.
- Settings → Conversions API → Set up manually → Generate access token, copy the token right away. If the link is missing: Business settings → Users → System users → assign the pixel to a system user → Generate token.
- In Matomo: Access token and Dataset (pixel) ID; target = event name such as
PurchaseorLead. - Test: Events Manager → pixel → Test events shows a code for the Test event code field. Clear it after setup, as Meta counts test events.
Error 190 (OAuthException): the token is invalid or revoked; generate a new one.
You need a role with edit rights in the ad account, such as Account Manager or Campaign Manager. No developer app is needed.
- Campaign Manager → ad account → Data → Signals Manager → Direct API → Generate access token and sign in with the LinkedIn account. LinkedIn shows the token only once; it does not expire.
- Conversion rule: in the ad account under Measurement → Conversion tracking, create a conversion with the data source Direct API (Conversions API) and associate it with the campaigns; campaigns without it get no conversions. The rule's ID is shown in the address bar when you open the rule.
- In Matomo: Access token and Ad account ID (the number after
accounts/in the address); target = ID of the conversion rule.
LinkedIn has no test mode. Errors: 401 = token missing or wrong; 403 USER_NOT_AUTHORIZED = no access to this ad account; Conversion enabled should be true = the rule is deleted or switched off.
X (Twitter)
The pixel ID is shown in X Events Manager (ads.x.com → Tools → Events Manager) at the event source, e.g. o8z6j. You can sign in two ways:
- Pixel token: Events Manager → event source → installation method Manual → Conversion API → Generate access token. You need access to Ads Manager with permission to manage Events Manager. X documents this token for its Google Tag Manager template; if X rejects it, use the OAuth keys.
- OAuth keys: create a developer account at developer.x.com, create an app and apply for Ads API access for it (Ads API Access form; the level Conversion Only is enough; the review takes a few business days). Then generate API key, API key secret, access token and access token secret under Keys and tokens, for a user with the role AD_MANAGER or ACCOUNT_ADMIN in the ads account. Regenerate access tokens created before the approval. The keys stay valid until they are regenerated.
In Matomo: Pixel ID and either Pixel token or the four keys, with OAuth also the Ads account ID for the connection test. Target = event ID of the conversion event from Events Manager. There is no test mode; a test conversion appears at the event in Events Manager after a short while.
Microsoft Advertising
Only someone with access to the account that owns the UET tag can generate a token; with a shared tag you can only copy an existing token.
- In the UET tags section, click the pencil of the tag → Save and next → under Set up tagging choose Use Conversions API → copy the token → Next → Done. The UET tag ID is shown in the list of UET tags.
- Create a conversion goal of type custom event whose action matches the event name you enter as the target in Matomo (e.g.
purchase). - In Matomo: Conversions API token and UET tag ID; target = that event name.
If Use Conversions API is missing, Microsoft Advertising support enables it for the customer ID that owns the tag. 401 You are not authorized to access this resource: the token is missing, wrong, expired or belongs to another tag; copy it again. There is no test mode.
ChatGPT Ads (OpenAI)
OpenAI must have enabled the ad account for the pixel and the Conversions API; if the options are missing, your contact at OpenAI can help.
- OpenAI Ads Manager → Conversions: create a pixel (data source) if there is none yet, and create a key for the Conversions API. It works only for this ad account; a normal OpenAI API key or the Ads API key does not work. Keep it like a password.
- In Matomo: Conversions API key and Pixel ID (the same pixel that runs on the website); target = event type such as
order_createdorlead_created. - Test connection sends a sample conversion that OpenAI only validates and does not store.
Authentication failure: wrong key type. Access denied: the account is not enabled, or the key belongs to another ad account.
TikTok Ads
You need admin access to the ad account in TikTok Ads Manager.
- TikTok Ads Manager → Tools → Events → Data sources → open the website's pixel. The pixel code is shown in the pixel's details.
- Settings → Events API → Generate Access Token → copy the token.
- For setup: copy the test event code from the pixel's Test events tab.
- In Matomo: Access token, Pixel code and optionally Test event code; target = standard event such as
PurchaseorLead. Clear the test event code after setup.
Authentication errors (code 40001 or 4010x): the token is wrong or revoked; generate a new one.
Consent in detail
Three modes per website
Set the mode per website under Administration → Websites → Manage → Consent for ad platforms.
- Strict (recommended): a conversion only goes to a platform or webhook if your website passed a consent signal for it.
- External: your website ensures consent itself, for example by loading Matomo only after consent. Conversions are sent unless a signal explicitly denies it.
- All visitors have consented: as the website owner you confirm that every visitor has consented (like in Google Ads and GA4) and are responsible for it. Conversions are sent without a consent signal, also with the platforms' cookies and the customer data from the dataLayer. Only an explicit refusal stops sending for that visitor, also when it comes after the conversion; a refusal via Google Consent Mode applies to every platform in this mode, a banner's default value before its answer does not count. For sending the mode applies at once; the browser script reads cookies and dataLayer customer data once the background job has rebuilt matomo.js. Matomo Tag Manager containers follow by themselves.
"External" and "All visitors have consented" both send without a consent signal and do not wait for a later consent. They differ like this:
| External | All visitors have consented | |
|---|---|---|
The platforms' cookies (_fbp/_fbc of Meta, _ttp/ttclid of TikTok, __oppref of ChatGPT Ads) |
only with a consent signal for the platform | always, unless refused |
Customer data from the dataLayer (user_data) |
only with a consent signal | always, unless refused |
| A banner's default value before the answer (e.g. Google Consent Mode "denied") | counts as a refusal | does not count, only the visitor's answer does |
| A refusal via Google Consent Mode | stops only Google (unless "Google Consent Mode applies to" is set to all platforms) | stops every platform |
| A refusal that comes after the conversion | is not taken into account, the conversion is still sent | stops the conversion as long as it is not sent yet |
| Takes effect | at once | sending at once; cookies and dataLayer customer data once the background job has rebuilt matomo.js |
In both modes customer data from setUserData is used, and Google gets consent reported as granted unless the visitor
refuses.
Which mode? "Strict" if your consent banner passes signals and only what was consented to should be sent. "External" if your banner passes signals but you want to send without a signal too; without a signal matching is weaker, because cookies and dataLayer customer data are missing. "All visitors have consented" if you collect consent elsewhere (e.g. Matomo and marketing load only after consent) or have another legal basis: the best matching, and a real refusal by the visitor still counts.
The signals
| Way | How you pass the decision | Applies to |
|---|---|---|
| Matomo Tag Manager | _mtm.push({event: 'fwcapi_consent', fwcapi_consent: {google: true, meta: false, awin: true}}) |
the platforms and webhooks it names |
| Google Tag Manager, gtag | the same entry in dataLayer |
as above |
| JavaScript API | _paq.push(['FeinwerkConversionsApi::setConsent', {google: true, meta: false}]), true for all, false for none |
as above; wins over entries in _mtm and dataLayer |
| Google Consent Mode v2 | gtag('consent', 'default' / 'update', {ad_storage: 'granted', ad_user_data: 'granted', …}) |
Google; depending on the website setting also all other platforms and webhooks |
| Microsoft UET Consent Mode | uetq.push('consent', 'default' / 'update', {ad_storage: 'granted'}) |
Microsoft Advertising |
| Server-side tracking, custom requests | parameters fwcapi_consent (all, none or e.g. google,meta), fwcapi_pc (per key, e.g. meta:1,linkedin:0,awin:1), fwcapi_cm (granted Consent Mode keys, e.g. ad_storage,ad_user_data, or none) |
as the ways above |
The keys of the seven platforms are google, meta, linkedin, x, microsoft, openai and tiktok. Every webhook has its own
Consent key, for example awin: lower-case letters, digits and underscore, 2 to 32 characters. Under Setup the
plugin page shows the matching code with the keys of all destinations of the website.
Rules
- Only the keys named: an
fwcapi_consententry only applies to the platforms and webhooks it names. Several entries add up, the later one wins. Up to 20 keys count per signal; the five platforms always count, and denials come before grants. - Google Consent Mode: releases Google when
ad_storageandad_user_dataare granted;ad_personalizationcontrols personalised ads. Whether Consent Mode also releases Meta, LinkedIn, X, Microsoft, ChatGPT Ads, TikTok Ads and the webhooks is set per website under Google Consent Mode applies to (default: Google only). Defaults withregiononly count as a denial. Anfwcapi_consententry forgooglewins over Consent Mode. - Microsoft UET Consent Mode:
grantedreleases Microsoft,deniedrefuses, before and after the UET tag has loaded. Anfwcapi_consententry formicrosoftwins. - Timing: the plugin reads the signals when Matomo sends a tracking request. Pass consent before the conversion; later entries apply to later requests.
Late consent and withdrawal
If the visitor answers your consent banner only after the conversion, for example for a goal reached on page view,
the conversion waits up to 24 hours for the decision. The plugin passes a later decision to Matomo by itself; it
applies to all conversions of this visitor not sent yet, also from earlier visits. A denial that only comes from
Google's or Microsoft's defaults (default) is not a decision yet; the banner's answer (update) decides. A
withdrawal stops everything not sent yet. Can be switched off per website under Wait for late consent (up to 24
hours); applies only in the mode Strict.
Examples
Report orders to ChatGPT Ads
In OpenAI Ads Manager under Conversions, create a pixel and a key for the Conversions API. In the plugin, add the destination ChatGPT Ads (OpenAI), enter pixel ID and key and map the ecommerce order to the target order_created with the revenue, your contact form to lead_created. Test connection lets OpenAI check key, pixel and a sample conversion without saving anything. Pass consent under the key openai (see Consent in detail). If the OpenAI pixel also runs on your website, choose Order ID, otherwise the event ID passed by the website under Deduplication with an existing pixel and give the pixel the same number as event_id.
Report conversions to Meta despite ad blockers
Add a Meta destination and assign the ecommerce order to Purchase with its revenue. If the Meta pixel keeps running, choose Order ID, otherwise the event ID passed by the website under Deduplication with an existing pixel: Meta then counts every order once, even if both pixel and plugin report it.
Report leads to LinkedIn
Assign the goal Contact request to a LinkedIn conversion rule and enter a fixed value, for example the average value of a lead. LinkedIn attributes the conversion to the campaign through the click ID li_fat_id, even if the request comes on a later visit.
Google Ads with orders and newsletter sign-ups
Add a Google destination with two conversion actions. Google recommends a send delay of about six hours so that fresh clicks are known to Google; the plugin presets it for Google. Until they are sent, the conversions are shown as Scheduled in the send log.
Which steps in the visit came before these orders and sign-ups is shown in Matomo by Visit Journey, for every goal and for ecommerce orders.
Pass conversions to n8n, Zapier or Make
This turns every order or enquiry into a new record in your CRM, a row in a spreadsheet or a message in your team chat. First set up the receiving end in the automation service:
- n8n: a workflow with the Webhook node, method POST. Enter the Production URL in the plugin, not the Test URL, and activate the workflow: only then does n8n accept requests. Header Auth protects the webhook; enter the same name and value in the plugin under Header name and Header value. A self-hosted n8n instance must be reachable via https from the internet.
- Zapier: a Zap with the trigger Webhooks by Zapier and the event Catch Hook. Enter the URL shown in the plugin. Webhooks by Zapier is only available on Zapier's paid plans.
- Make: a scenario with the module Webhooks and Custom webhook. Enter the URL shown in the plugin. If you set an API key there, enter
x-make-apikeyas Header name and the key as Header value in the plugin.
Then add a destination Webhook / Postback in the plugin with this URL, method POST, format JSON:
- Leave Click ID parameters empty. Then the attribution stays at Send every conversion, and every conversion arrives.
- Without a Body template the plugin sends every placeholder, including IP address, user agent and hashed customer data. A template sends only what your workflow needs. Placeholders go in quotes; a placeholder that is a whole value is filled with numbers and lists as such, for example
{"order_id": "{{order_id}}", "event": "{{target}}", "value": "{{value}}", "currency": "{{currency}}", "items": "{{items}}"}. - Give it a Consent key such as
n8nand include it in your website's consent signal (mode Strict, see Consent in detail).
Zapier and Make learn the fields of a request from a first sample. Click Send test request in the list of destinations: after a confirmation the plugin sends a sample conversion with the order ID TEST-1 and shows the service's answer. n8n receives it while the workflow is active. If the workflow is switched off or the webhook URL deleted, the plugin retries real conversions for up to 7 days; if a destination reports only errors for 24 hours, the administrators get an e-mail.
Feedback and support
From version 5.0.0 on, Conversions API asks below the setup help on the plugin page whether your conversions reach the destinations. Tell us with thumbs up or down; next to it, Support opens Feinwerk's contact form. Your Matomo server sends only the answer with the plugin and Matomo version, the browser and the interface language to Feinwerk, nothing about you, your websites or your visitors. To switch the question off, add this to config/config.ini.php:
[FeinwerkConversionsApi]
feedback = 0
If you switched off Matomo's internet features (enable_internet_features = 0 in the [General] section), nothing is sent.
Good to know
- Consent: In the default mode Strict, only what the visitor consented to is sent, per platform. Choose the mode External per website if your website ensures consent itself (Administration → Websites → Manage). If you confirm every visitor's consent yourself, choose All visitors have consented.
- Late consent: If the visitor answers the banner only after the conversion, for example for a goal reached on page view, the conversion waits up to 24 hours for the decision. The plugin passes a later decision to Matomo by itself; it also applies to conversions from earlier visits and to goals tracked server-side. A withdrawal stops everything not sent yet. A denial that only comes from Google Consent Mode's defaults is not a decision yet. Can be switched off per website with Wait for late consent.
- Privacy: Customer data is normalised and hashed in Matomo; plain text is never stored. Full IP address, user agent and hashes are deleted after sending, at the latest after 7 days, click IDs after 90 days. While a conversion waits for consent, IP address and user agent are kept encrypted for up to 24 hours, only for platforms with a destination on the website. Matomo's raw data deletion and GDPR tools cover the plugin's data.
- User ID and cookieless tracking: An ad click from an anonymous visit also counts for a conversion after login, as long as the same browser with the same Matomo cookie is used. Without a visitor cookie, Matomo recognises a visitor only within the same day.
- E-mails on problems: Matomo writes to the super users and the website's administrators when a destination is paused after an authentication error, has only reported errors for 24 hours or is switched off, at most once per incident and level. Super users can switch this off under Administration → System → General settings → E-mail on problems with destinations. Matomo must be allowed to send e-mails.
- Copying to other websites: The copy icon in the list of destinations copies a destination with its credentials, settings, the attribution with time window and markers and the goals to send to other websites you administer. Goals are matched by their name, the ecommerce order only on websites with ecommerce. Websites that already have the destination are skipped.
- Troubleshooting: After an authentication error a destination pauses for at least an hour; after five in a row it is deactivated. If Matomo's salt changes, enter the credentials again. The plugin page shows the license status, checked via the Feinwerk Marketplace Connector; the plugin keeps working without a valid license. More help: support@feinwerk.io.
- Free trial: With the Feinwerk Marketplace Connector you can try the Conversions API free of charge for 30 days. If the trial ends without a purchase (from one day after the end date), the plugin keeps capturing click IDs and conversions, and all destinations and settings stay. Until you buy a license, only sending to the destinations, the connection tests and the polling of platform diagnostics pause. After the purchase, the waiting conversions of the last 7 days go to the destinations, as far as the platforms still accept them.
Tips from Feinwerk
Below the feedback question on the plugin page the plugin shows one short line with a tip on another Feinwerk offer, for example Feinwerk Campaigns. Only users with admin access to at least one website and super users see it, and only in Matomo's interface: never in exports, API results, email reports or embedded widgets. A tip for a Feinwerk plugin you already have installed is not shown. "×" hides the tip for 30 days in your browser. The tip is part of the plugin: nothing is loaded from outside and nothing is sent. The link opens a feinwerk.io page in a new tab and carries only the campaign parameters mtm_campaign, mtm_source and mtm_content. To switch the line off, add to config/config.ini.php:
[FeinwerkConversionsApi]
promotions = 0
The same line in the section [FeinwerkMarketplaceConnector] switches the tips of all Feinwerk plugins off. Recent versions of the Feinwerk Marketplace Connector also have the setting "Show notes on other Feinwerk offers".
Technical reference
| Property | Value |
|---|---|
| Technical name | FeinwerkConversionsApi |
| Current version | 6.2.0 |
| Matomo | ≥ 6.0.0, < 7.0.0-b1 |
| PHP | ≥ 8.1.0 |
| License | paid |
| Database changes | none in the current version |
FAQ
Which platforms are supported?
Google Ads via the Data Manager API, Meta (Facebook and Instagram) via the Conversions API, LinkedIn via the Conversions API, X (Twitter) via the web conversions of the X Ads API, Microsoft Advertising (Bing) via the UET Conversions API, ChatGPT Ads (OpenAI) via OpenAI's Conversions API and TikTok Ads via TikTok's Events API. You can set up as many destinations per website as you like.
Can I send conversions from Matomo to ChatGPT Ads?
Yes, from version 5.1.0. In OpenAI Ads Manager under "Conversions" you create a pixel and a key for the Conversions API and enter both in the plugin. Orders go to OpenAI as "order_created", enquiries as "lead_created", other goals under an OpenAI type or a name of your own. The plugin recognises clicks from ChatGPT ads by itself. OpenAI must have enabled your ad account for the Conversions API; OpenAI decides in which countries ChatGPT ads run.
What changes for Microsoft Advertising?
Microsoft opened its Conversions API to all ad accounts on 28 October 2026; before, it was a pilot enabled per account. Conversions API has supported it since version 0.4.0 and now also sends the page URL of every conversion. All you need is the ID and the token of your UET tag.
Can I pass conversions to n8n, Zapier or Make?
Yes, with the destination "Webhook / Postback". Enter the webhook URL from n8n ("Webhook" node), Zapier ("Webhooks by Zapier", "Catch Hook") or Make ("Custom webhook"). The plugin sends every conversion on its own as JSON, for example with order ID, goal, value and the items of an order. Your workflow then passes it on to a CRM, a spreadsheet or a chat. The address must be reachable via https from the internet. "Webhooks by Zapier" is only available on Zapier's paid plans.
Do I need Google Tag Manager?
No. You pass consent, customer data and order ID via Matomo Tag Manager (_mtm) or Matomo's JavaScript API. If your website uses Google Tag Manager or Google Consent Mode, the plugin reads those entries as well.
Can I keep the pixel running in parallel?
Yes. When running both, the platforms deduplicate via a shared event ID: either the order ID or an ID your website passes to the pixel and to Matomo.
How do I prevent two affiliate partners from being paid for the same order?
Set the attribution of the partners' webhooks to "Only if this source was the last contact". Then only the partner the visitor came through last gets the conversion; direct visits do not count. The plugin recognises the source by the partner's click ID and optionally by the campaign source.
How fast do conversions arrive?
With the recommended cron job the plugin checks every minute what to send. For Google a delay of about 6 hours is preset, so that fresh clicks are already known to Google.
What happens without consent?
In the default mode "Strict" nothing is sent to a platform without consent. If the visitor answers the consent banner only after the conversion, the conversion waits up to 24 hours for the decision; without consent it is dropped and its data deleted. If the website owner ensures consent elsewhere, they can choose the mode "External" per website.
Which Matomo version do I need?
Matomo 6 or Matomo 5 with PHP 8.1 or newer, also for the command line that runs the cron job. The plugin supports Matomo's dark mode.
Where do I find the Conversions API in Matomo?
Administrators of a website find it under Administration → Websites → Conversions API and in the reports under Goals → Conversions API. There you set up destinations, check the send log and find the code for your website.