Skip to main content

Track Google Ads campaigns using Matomo

How can I track Google Ads campaigns using Matomo?

by Aleksandra Tomic

15.03.2023

Matomo

We show you how you can measure and analyze the performance of your Google Ads ads with Matomo. Learn how to use URL suffixes and tracking parameters to obtain key figures via Matomo.

Since the European Court of Justice (ECJ) decided to tighten up the General Data Protection Regulation (GDPR), more and more companies are switching from Google Analytics to Matomo. The big advantage of Matomo is that it gives users complete control over their tracking data. You can install the system on your own server and send all tracking requests there. In this way, Matomo ensures that the data collected cannot be used by third parties.
Campaign and conversion tracking are decisive when it comes to the question: which measures work better, which worse? The findings can be used to optimize advertising expenditure and significantly improve the overall return on investment. In this article, we will show you what you need to track Google Ads campaigns with Matomo and how you can carry out the conversion setup.

Google Ads Kampagnen mit Matomo messen

Google Analytics and Google Ads are closely intertwined. Google offers us Salesforce as the only direct integration for Google Ads, but not the direct competitor Matomo. However, there is a simple manual method that can be used to link Matomo and Google Ads. It’s quick and only requires a small script.
There are two methods: manual and automated.

Method 1: manual set-up campaign tracking with additional tracking parameters

If you only want to measure individual ads, Matomo provides you with the campaign URL builder.

The only required parameters are the campaign name (mtm_campaign) and the link to the landing page, all other parameters are optional and can be customized to your needs

  • mtm_campaign: the name of your Google Ads campaign
  • mtm_kwd: the keyword to be assigned to this Google Ads campaign
  • mtm_source: the source of your Google Ads campaign (in this case “Google Ads”)
  • mtm_medium: the source type (cpc, cpm, cpa, etc.), in this case cpc (cost per click)
  • mtm_content: the content of your ad
  • mtm_cid: a campaign ID for your ad

A target URL with MTM parameters can look like this, for example:

Art-Director-Brand-und-Webdesign&mtm_cid=a01

Since each ad URL can be triggered by different keywords and can correspond to different campaigns or headlines, you have to adjust the campaign parameters for each URL, which can take quite a long time. Therefore, there is another option that is much faster.

Method 2: automated Google Ads setup to track with Matomo

The more elegant option is to store the tracking parameters globally as a tracking template via Google Ads. This saves you the work of storing individual MTM parameters for each individual campaign, ad group or ad. Instead of working with fixed parameter values, dynamic placeholders, the so-called ValueTrack parameters, are used here.
You can define the tracking templates either at account, campaign or ad group level. For example, if you use a tracking template at account level, all your campaigns will have the landing page with the URL parameters that you have defined in the tracking template. At campaign level, this means that all ad groups within a campaign have the target page with the respective parameter.
Each tracking template defined in a campaign overwrites a tracking template defined at account level. This allows you to define the tracking template at all levels. This means that campaigns for which you have not stored a tracking template will still be measured (as the template at account level applies here).

svg+xml;charset=utf dmcgroup

There are certain parameter values that can be used for the URL options. Google Ads gives us a few tips in the Google Ads Help. Not all parameter values are permitted for every campaign. For example, a shopping campaign has different parameters than a display campaign. You must therefore enter the correct tracking parameters when splitting at account, campaign and ad group level.

Here we show you an example of a Google search ad campaign at campaign level. You can see which parameters can be used in the list in the Google Ads Help. You check which parameters you can link from Matomo to those of Google Ads and then create a tracking template with the respective parameters.

Example: For a search network ad, the search term used by users to reach the landing page from an ad is to be analyzed. For this purpose, the dynamic keyword placeholder for the Matomo parameter is defined as follows: mtm_kwd= {keyword}

At account level, the following tracking template is stored in the account settings:

{lpurl}?mtm_campaign={_campaignname}&mtm_kwd={keyword}&mtm_source=googleads&mtm_medium={_adgroupname}&mtm_content={creative}

For the parameter values {_campaignname} and {_adgroupname} are user-defined parameters that are assigned by the advertiser. A fixed value is defined for the user-defined parameter _campaignname in the campaign settings for each campaign. The same is done at ad group level (_adgroupname) and, if required, at ad level (_adname).

The values {keyword} and {creative} are generated dynamically and transferred to Matomo.

svg+xml;charset=utf dmcgroup

Each URL parameter in Google Ads can be automatically filled with a function called “Tracking template”.

Set up conversion import in Google Ads

As with any conversion tracking setup, you must first decide which Matomo goals you want to export to Google Ads. These goals must be set up in Google Ads as external click conversions.
Click on “Tools and settings” under “Measurement> strong conversions”.

svg+xml;charset=utf dmcgroup

For each conversion you want to add:

  • Click on “+New conversion action”
  • Select “Import”
  • Select “Other data sources or CRM systems” and then “Record click conversions”
  • Click “Next”
  • Give the conversion a name (this name must be used later in Matomo, but does not have to match a target name in Matomo)
  • Select a setting for “Value” and “Number” as required and configure the assignment settings
svg+xml;charset=utf dmcgroup

The use of URL options or tracking templates is a prerequisite for being able to evaluate Google Ads campaigns via Matomo. With the help of these measures, valuable conclusions can be drawn from the key usage figures, which is essential for professional and data-based optimization. This refers not only to advertising measures via Google Ads, but also to Microsoft Ads or social media campaigns.

We are more than just experts – our dedicated team of designers, developers and marketing specialists work hand in hand to take your digital presence to the next level.

Ready for the next step?
Contact us and find out more about our services.

Evaluate campaigns in Matomo

After the set-up, we can evaluate the current campaigns in Matomo and optimize them based on the results. We find the overview in Akqusition -> campaigns.
Here you will find the campaigns you have created and the details of these.

svg+xml;charset=utf dmcgroup

There are also many other free and paid plug-ins that significantly expand the range of functions in Matomo and the evaluation. Including a tag manager.

Frequently asked questions

What is website tracking and why is it important?

Website tracking is the collection and analysis of visitor data and their interactions on a website.
With website tracking, for example, you can find out:

  • Who are my visitors and are they also my desired target group?
  • From which backlinks did the users come to my website?
  • Which keyword led to the website visit?
  • How long is the dwell time on specific pages?

If the data obtained is incorporated into the online marketing strategy, the use of tracking can help to make your website even more successful and generate business success.

What tracking tools are available?

The best-known tracking tools include Google Analytics, Adobe Analytics and Matomo (formerly Piwik).

What is a tracking concept?

With the help of tracking concepts, you can gain an overview of the efficiency and impact of individual online activities. Not everything that can be measured is relevant for every company. With the help of the previously defined goals, you can start designing your tracking and define the most important KPIs for your company. It is up to you which form you choose – written, graphical, tabular or another form.

From the latest industry trends and the latest insights into AI and UX/UI design to exciting use cases.

Sign up for our monthly newsletter and stay up to date!

Heading3 for SEO Hierarchy