Matomo

Matomo

Open-source web analytics platform that self-hosting teams use as a privacy-respecting alternative to Google Analytics. Matomo tracks page views, events, goals, and funnels. Can operate without cookies when configured for cookieless tracking, keeping all data under the site owner's control.

Overview

Matomo (formerly Piwik) is an open-source web analytics platform that organizations self-host as a privacy-respecting alternative to Google Analytics. It tracks page views, events, goals, conversions, and funnels while keeping all data under the site owner's direct control.

What This Script Does

The Matomo tracking script (matomo.js or piwik.js) operates differently depending on configuration:

Standard mode (with cookies):

  • Sets first-party cookies to identify returning visitors, track session duration, and attribute conversions across visits. The default cookie prefix is _pk_ with configurable expiration (typically 13 months for the visitor cookie, 30 minutes for the session cookie).
  • Records page views (URL, page title, referrer), site search queries, outbound link clicks, and file downloads.
  • Sends tracking requests to the site owner's Matomo server (self-hosted) or Matomo Cloud instance on each page event.
  • Supports custom event tracking, goal conversions, and e-commerce transaction logging.

Cookieless mode:

  • When configured with disableCookies(), Matomo tracks without setting any cookies. It uses a combination of IP address and user agent to generate a daily-rotating visitor hash for basic visit counting.
  • In this mode, returning visitor recognition is limited (visitors are treated as new each day), but page view and event tracking still functions.
  • This mode significantly reduces ePrivacy compliance requirements.

Data stays on your server (self-hosted):

  • Unlike Google Analytics, self-hosted Matomo does not share data with any third party. All analytics data is stored on infrastructure the site owner controls.
  • Matomo Cloud is hosted by Matomo's company (InnoCraft) on EU-based servers, with a DPA available.

IP anonymization:

  • Matomo supports IP anonymization (masking 1-3 octets) which can be enabled in the admin panel. When fully anonymized, the stored data does not contain complete IP addresses.

Do Not Track:

  • Matomo can be configured to respect the browser's Do Not Track (DNT) header, skipping tracking entirely for users who have enabled it.

Consent & Compliance

Matomo is an analytics tool, but its compliance posture varies significantly by configuration:

Under GDPR:

  • Self-hosted + cookieless + IP anonymization: Several European data protection authorities (including CNIL in France) have confirmed that Matomo can be used without consent when configured with cookieless tracking, IP anonymization, and self-hosting. In this configuration, Matomo qualifies for the "strictly necessary" or "legitimate interest" exemption because no personal data leaves the site owner's control and no cookies are set.
  • Standard mode with cookies: Requires consent under GDPR/ePrivacy because it sets non-essential cookies for analytics purposes.
  • Matomo Cloud: Requires a DPA with InnoCraft. May still qualify for consent-free use if cookieless mode is enabled and the CNIL-approved configuration is followed.

Under ePrivacy:

  • Cookieless mode avoids the cookie consent requirement entirely.
  • Standard mode with cookies requires consent for setting the analytics cookies.

Under CCPA:

  • Self-hosted Matomo does not share data with third parties, simplifying CCPA compliance. Disclosure in the privacy policy is still required.

Should You Block This Without Consent?

Conditional. If Matomo is self-hosted with cookieless tracking and IP anonymization enabled, it can run without consent — this is one of the few analytics tools that can legitimately operate consent-free. If using standard cookie-based tracking, it should be blocked until analytics consent is granted. Check your specific Matomo configuration before deciding.

Is Matomo GDPR compliant?

Matomo typically loads analytics trackers, which are not strictly necessary for your site to work. Under the GDPR and the ePrivacy Directive, non-essential cookies and trackers must stay blocked until a visitor gives clear opt-in consent. So Matomo can be fully GDPR compliant, but only if your site holds its scripts until consent is granted and lets visitors decline just as easily. Compliance depends on how your site loads Matomo, not on Matomo itself.

Visit website

Consent Categories

Also Known As

matomopiwikpiwik analyticsopen source analyticsself-hosted analyticscookieless analyticsgoogle analytics alternativeGDPR analytics

Industries

Computers Electronics and Technology

Tracked Domains (2)

matomo.orgAnalytics

matomo.org is an analytics domain operated by Matomo, used to measure visits, sessions, and on-site behavior.

cdn.matomo.cloudAnalytics

cdn.matomo.cloud is an analytics domain operated by Matomo, used to measure visits, sessions, and on-site behavior.

Cookies Matomo Sets (2)

_pk_id.

Matomo persistent visitor identifier (also set by Piwik PRO, which shares the same codebase). Full name is _pk_id.<site-id>.<hash>; the dot-separated suffix encodes the Matomo site identifier.

_pk_ses.

Matomo short-lived session marker (also set by Piwik PRO, which shares the same codebase). Full name is _pk_ses.<site-id>.<hash>; the dot-separated suffix encodes the Matomo site identifier.

Frequently Asked Questions

Related Vendors

Joomla
Joomla
Loads core CMS functionality scripts on Joomla-powered websites, including extension integrations and component libraries. Third-party Joomla extensions may load additional scripts that collect usage analytics or personal data depending on the plugins installed and configured by site operators.
Tawk.to
Tawk.to
Tawk.to is a free live chat and customer messaging platform used across millions of websites. Scripts embed a chat widget that connects site visitors with support agents in real time. Visitor data including IP address, browser, location, and pages viewed is visible to agents and stored in tawk.to's dashboard.
Pendo
Pendo
Product engagement and analytics platform used by SaaS companies to understand and guide user behavior. Pendo tracks feature usage, in-app events, and NPS scores. Also delivers in-app guides, tooltips, and onboarding walkthroughs via an injected overlay script.
Plausible
Plausible
Lightweight, privacy-focused web analytics platform designed for GDPR compliance without cookie consent banners. Plausible tracks page views and referral sources without setting cookies or collecting personal data. All data is aggregated and not shared with third parties.
Bing Webmaster Tools
Bing Webmaster Tools
Sets a meta tag or BingSiteAuth.xml file to confirm site ownership with Microsoft Bing. The verification asset collects no personal data; Bing then provides search performance, crawl error, and keyword analytics accessible only through authenticated Webmaster Tools dashboard sessions.
Exponea
Exponea
Collects real-time behavioral events, page views, and session data for customer journey analysis and segmentation. Enables personalized content delivery, product recommendations, and automated marketing workflows through the Bloomreach Engagement CDP (formerly Exponea).

Manage consent for Matomo

ConsentStack automatically detects and manages Matomo trackers so your site stays compliant with global privacy regulations.