Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
WPB Cup
30 Million+
Websites using our plugins
20+
Years of WordPress experience
3000+
WordPress tutorials
by experts

How to Setup Matomo Analytics in WordPress (The Easy Way)

Want to understand how visitors find and use your website without relying on Google Analytics? Matomo Analytics is a great tool that gives you detailed traffic and user behavior reports while keeping your data under your control..

In this guide, we’ll show you how to set up Matomo in WordPress,

How to Set Up Matomo Analytics in WordPress

What Is Matomo Analytics & How Does It Work in WordPress?

Matomo is an open-source analytics platform that gives you more control over your website data. With the self-hosted version, your analytics data is stored on your own server rather than being shared with a third party like Google. If you’re concerned about privacy, Matomo gives you greater control over your analytics data

In WordPress, Matomo works as a plugin, so you can manage your analytics directly from your WordPress dashboard. It tracks your visitors and turns that information into reports about your website traffic, conversions, and user behavior.

Next, we’ll show you how to set up Matomo in WordPress. Use the jump links below to skip to the section you need:

How to Set Up Matomo Analytics in WordPress

Before getting started, make sure your WordPress site meets Matomo’s requirements.

The Matomo for WordPress plugin requires WordPress 4.8, PHP 7.2.5, and recommends a minimum of 256MB of memory. The Matomo plugin works well on small sites with fewer than about 50,000 pageviews per month. Beyond that, resource usage can put more strain on your hosting.

There are three ways to run Matomo. ‘Matomo for WordPress’ installs it as a plugin, so it lives inside your site. Matomo On-Premise is the same software installed on your own server as a separate application, which handles much more traffic. Matomo Cloud is hosted by Matomo, so you manage nothing, but your data sits with them.

For this guide, we’re going to use Matomo for WordPress, which is an all-in-one solution that runs directly on your WordPress site. This way, you won’t need to create an external account or manage separate servers.

Matomo for WordPress' banner
Step 1: Installing the Matomo for WordPress Plugin

The first step is to install and activate the Matomo for WordPress plugin. Go to Plugins Ā» Add Plugin in your WordPress dashboard, and then use the search feature to quickly find the plugin. Simply type in ‘Matomo for WordPress’ and hit Enter.

Next, click the ‘Install Now’ button and then ‘Activate.’ For detailed instructions, check out our guide on how to install a WordPress plugin.

Installing Matomo Analytics
Step 2: Enabling Matomo Tracking on Your WordPress Site

Once you activate Matomo, go to the Matomo Analytics Ā» Get Started page.

From there, follow the setup wizard to configure the basic settings. You’ll need to complete 2 steps: updating your privacy policy page and enabling Matomo Analytics tracking. The plugin will then save and apply your new settings.

Update Your Privacy Policy

The first step is to update your Privacy Policy page.

Getting started with Matomo Analytics

Here, Matomo asks you to make sure your Privacy Policy reflects a commitment to user privacy and compliance with regulations like GDPR and ePrivacy.

This includes giving users the option to opt out of tracking. You can easily add this by pasting the [matomo_opt_out] shortcode or adding the Matomo opt-out block directly to your Privacy Policy page.

If you don’t have a Privacy Policy page yet, our guide on how to add a privacy policy in WordPress walks you through creating one from Settings Ā» Privacy, including how to add the opt-out shortcode.

Creating a privacy policy page in WordPress
Enable Matomo Tracking

After updating your privacy policy, you should be ready to enable Matomo tracking on your WordPress site. On the Get Started page, click the ‘Enable tracking now’ button.

Enable Matomo tracking

Once enabled, you’ll see a green checkmark and a success notification.

Matomo may take a little time to start collecting data, so don’t worry if you don’t see analytics right away. Check back in a few hours to see your first visitor statistics.

Matomo tracking enabled

If you’re using a caching solution through a caching plugin or your hosting provider, clear your cache so your site recognizes the new setup and starts tracking visitors.

For details, see our tutorial on how to clear your cache in WordPress.

Step 3: Navigating Through the Analytics Dashboard

Once Matomo is tracking your site, here’s a quick orientation to where everything lives.

For a quick overview without leaving your WordPress dashboard, go to Matomo Analytics Ā» Summary. This embedded report gives you an at-a-glance view of visits, top countries, and visitor devices. If you run an online store, you’ll also see basic order and product stats.

Matomo summary inside WordPress admin

For the full analytics interface, with detailed reports on visitor behavior, acquisition channels, and conversion goals, go to Matomo Analytics Ā» Reporting in your WordPress admin area. This opens the full Matomo dashboard in a new tab.

Matomo dashboard accessible through WordPress admin

Matomo also includes its own Tag Manager at no extra cost. Like Google Tag Manager, it lets you add tracking scripts and pixels without editing code.

You’ll find it under Matomo Analytics Ā» Tag Manager. However, do note that it isn’t compatible with WordPress Multisite.

Matomo Tag Manager accessible through the WordPress admin

Top Matomo Alternative Plugin for WordPress Users

Matomo is a great choice if you want to keep your visitor data on your own server. If you’re considering Matomo mainly for GDPR, keep in mind that Google Analytics can also be configured to meet privacy requirements.

All you have to do is use a Google Analytics plugin like MonsterInsights. This plugin is used by over 3 million active installations. It simplifies GDPR compliance through its EU Compliance addon, which helps configure Google Analytics with privacy-friendly settings.

For more options, see our list of the best analytics solutions for WordPress users.

FAQs About Matomo Analytics

Here are the answers to some of the most frequently asked questions about Matomo.

Is Matomo really free?

Yes. Matomo offers a free, open-source version called Matomo On-Premise. It’s self-hosted, so you install the software and store your data on your own server, giving you full control. Matomo also offers paid cloud-hosted plans if you’d rather have them handle the hosting.

Does Matomo slow down a WordPress website?

Yes, to some degree. Because Matomo processes and stores analytics data on your server. It also adds a request per pageview and periodically runs a background process called archiving to build reports.

For a single site with fewer than about 50,000 pageviews a month, most modern WordPress hosting should handle this without a noticeable difference. With higher traffic or shared hosting, the extra server load becomes more noticeable. Matomo suggests moving to Matomo On-Premise at that point, which keeps your data on your own server, or to Matomo Cloud if you would rather not manage one.

Does using Matomo mean I can remove my cookie consent banner?

Not automatically. By default, Matomo uses cookies to track visitors, so most sites will still need a consent banner. Matomo also supports cookieless tracking, which may reduce or, in some jurisdictions, remove the need for consent. However, the rules vary by region.

Check with a privacy professional before removing your consent tools, especially if you serve visitors in the EU or UK.

My visits show up but my reports are empty. What’s wrong?

This is usually related to Matomo’s reporting process. The visit log updates quickly, while aggregated reports are built by a periodic process called archiving, which can take a few hours to catch up, especially after setup.

If your reports are still empty after that, the most likely cause is WP-Cron, which is what Matomo uses to run archiving. Some hosts disable it, and Matomo offers browser-based archiving as an alternative. Then check whether your caching plugin or hosting provider is preventing the tracking code from loading, and clear your cache. Ad blockers and privacy-focused browser extensions can also block analytics requests, so try testing in an incognito window with extensions disabled.

We hope this guide helped you set up Matomo on your WordPress site. For more tracking tips, check out our guides on how to see search analytics in WordPress and how to set up WordPress heatmaps.

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Disclosure: Our content is reader-supported. This means if you click on some of our links, then we may earn a commission. See how WPBeginner is funded, why it matters, and how you can support us. Here's our editorial process.

The Ultimate WordPress Toolkit

Get FREE access to our toolkit - a collection of WordPress related products and resources that every professional should have!

Reader Interactions

Comments

  1. Congratulations, you have the opportunity to be the first commenter on this article.
    Have a question or suggestion? Please leave a comment to start the discussion.

Leave A Reply

Thanks for choosing to leave a comment. Please keep in mind that all comments are moderated according to our comment policy, and your email address will NOT be published. Please Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.