In the intranet, visitors are signed in and work in-house. That is exactly why the analysis needs clear limits: you measure content, areas and searches, not people. On top of that come technical quirks a public website does not have: security rules of the platform, many individual sites, documents and single sign-on.
SharePoint Online: Tag Manager via an SPFx extension
For modern SharePoint pages, Matomo describes two ways. One inserts the code page by page with the Script Editor. The other is an extension in the SharePoint Framework (SPFx), an Application Customizer that loads the Matomo Tag Manager container on every page. For SharePoint, Matomo recommends the Tag Manager over the plain tracking code, because changes can then be made in Matomo without editing pages in SharePoint.
Since 2026, only the second way remains. SharePoint Online enforces a Content Security Policy on modern pages, from 1 March 2026, with a delay from 1 June 2026. For tracking, this means:
- Inline scripts no longer run. This affects the Script Editor, whose inserted script according to Microsoft is no longer executed, and equally tags in the Tag Manager that insert their own inline script.
- Scripts from other addresses need approval. Matomo’s address, from which the container and tracking code load, belongs in the trusted script sources in the SharePoint admin center.
- The extension is deployed centrally. The package goes into the App Catalog and applies to selected sites or the whole tenant.
One detail often makes the difference: within a site, SharePoint often switches pages without reloading them completely. The extension then does not start again. For every page change to count as a view, you need a trigger for it, such as the event SharePoint fires after each navigation, or a history change trigger in the Tag Manager.
Classic sites and SharePoint in-house: for classic sites, Matomo points to a PowerShell script that inserts the code, for older versions such as SharePoint 2013 to the master page. Modern pages in SharePoint Server 2019 follow the way for SharePoint Online.
Adobe Experience Manager: via the page component or a client library
In Adobe Experience Manager (AEM), the container goes where all pages get their header or footer: into the project’s page component, for example in customheaderlibs.html, or as a client library included by the template or page policy. It ships with the rest of the code, in AEM as a Cloud Service through the Cloud Manager pipeline.
Many AEM projects also bring data Matomo can put to good use. Pages based on the Core Components can use the Adobe Client Data Layer; in projects generated from the AEM Project Archetype version 24 or later it is active from the start. From it, the Tag Manager reads a page’s template, language and path, for example, and passes them to Matomo as custom dimensions.
What you can analyse
- Search: which terms are searched and which searches find nothing. If the search term is in the address of the results page, Matomo’s site search recognises it; otherwise a tag reports the search, and with the number of results Matomo also shows searches without results.
- News and areas: which news items are read and which areas hardly anyone uses, broken down by area, page type or language, for example.
- Documents: if a link ends in a file extension such as .pdf or .docx, Matomo counts the click as a download. Links that open a document in the browser are reported by a tag in the Tag Manager.
- Paths: from which start page employees go where, and where they need the search because the navigation does not help.
What makes intranet analytics useful
- Search firstSearches without results show fastest what is missing.
- Areas as a dimensionArea, page type and language make reports readable for editors.
- One container for everythingOne extension, one container, maintained in Matomo.
Typical pitfalls
- Scripts per pageUnder the Content Security Policy they no longer run.
- Only one view per visitPage changes without a reload get lost.
- People instead of contentUser IDs rightly bring the works council and data protection into play.
Measuring without personal data
Intranet analytics concerns employees. That is why tracking runs without a user ID and with masked IP addresses; the reports show content, not people. The works council or staff council belongs at the table early, with a technical description of what is measured and what is not. How Matomo measures without cookies is covered in Matomo without cookies; the legal assessment stays with your legal advisers.
In-house, with single sign-on
Intranet data does not belong in a third-party service. Matomo runs in your own data centre or your cloud; what operations involve is covered in Matomo hosting. Signing in to Matomo itself can run through the same identity provider as the intranet, with permissions from the existing groups.
Sources
As of 12 November 2026
- Matomo: Tag Manager in modern SharePoint pages via an SPFx extension
- Matomo: Tracking code in modern SharePoint pages
- Matomo: SharePoint Online and SharePoint on-premises
- Microsoft: Content Security Policy in SharePoint Online
- Microsoft: navigatedEvent in the SharePoint Framework
- Adobe: Including scripts in the page component
- Adobe: Adobe Client Data Layer with the Core Components
- Feinwerk: Auth SAML
