PHPackages                             wikifab/google-analytics-metrics - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. wikifab/google-analytics-metrics

ActiveMediawiki-extension[Utility &amp; Helpers](/categories/utility)

wikifab/google-analytics-metrics
================================

1.0.1(7y ago)03.2k2PHP

Since Jun 25Pushed 7y ago2 watchersCompare

[ Source](https://github.com/Wikifab/mediawiki-extensions-GoogleAnalyticsMetrics)[ Packagist](https://packagist.org/packages/wikifab/google-analytics-metrics)[ RSS](/packages/wikifab-google-analytics-metrics/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (3)Versions (4)Used By (2)

Description
===========

[](#description)

Google Ananlytics Metrics allow you to use Google's API and then you can published some statistic. However on the 1.29 version of Mediawiki some classes and stuff have been removed so we change few things. We need to display the counter view per page.

Installation
============

[](#installation)

1. Clone GoogleAnalyticsMetrics into the 'extensions' directory of your mediawiki installation and call it 'GoogleAnalyticsMetrics'.
2. Add the folling Line to your LocalSettings.php file :

    wfLoadExtension('GoogleAnalyticsMetrics');
3. Add those lines too to your LocalSettings.php file with your own values :

For this step, please follow the instructions at

```
$wgGoogleAnalyticsMetricsAllowed ='*'; // the "*" allow all metrics
$wgGoogleAnalyticsMetricsServiceAccountPath ='Your/Path/To/YourJsonFileName.json';
$wgGoogleAnalyticsMetricsEmail='your client_email in your json file';
$wgGoogleAnalyticsMetricsViewID = 'This is your account's id you can find directly on Google Analytics in your settings.';
$wgGoogleAnalyticsMetricsDevelopersKey = 'your private Key in your json file';
$wgGoogleAnalyticsMetricsAppName = 'The name of you application';

```

You might have trouble getting it to work and get this error "User does not have sufficient permissions for this account". In which case, for $wgGoogleAnalyticsMetricsViewID, use the table id instead of your account's id, which you can find on the management page under view (parameters -&gt; view id)

```
// Load the Google API PHP Client Library.
require_once __DIR__ . '/vendor/autoload.php';

```

\#How to use it ?

For instance if you want to display the page view's counter you just have to add this line on the page you want it :

```
{{#googleanalyticsmetrics:pageviews}}

```

Dependencies
============

[](#dependencies)

This extension works with the Extension:GoogleAnalytics.

MediaWiki Versions
==================

[](#mediawiki-versions)

This extension has been tested on MediaWiki version 1.29.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 55.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

2880d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/26b7c13f6509e6d6fdcddbc50c1e8e3d3bbd8dc905f84c83203687549a37dc15?d=identicon)[pyro853](/maintainers/pyro853)

---

Top Contributors

[![translatewiki](https://avatars.githubusercontent.com/u/24829418?v=4)](https://github.com/translatewiki "translatewiki (19 commits)")[![umherirrender](https://avatars.githubusercontent.com/u/1174884?v=4)](https://github.com/umherirrender "umherirrender (4 commits)")[![pierreboutet](https://avatars.githubusercontent.com/u/447459?v=4)](https://github.com/pierreboutet "pierreboutet (2 commits)")[![SoleneMoins](https://avatars.githubusercontent.com/u/26110781?v=4)](https://github.com/SoleneMoins "SoleneMoins (2 commits)")[![tosfos](https://avatars.githubusercontent.com/u/10228795?v=4)](https://github.com/tosfos "tosfos (2 commits)")[![siebrand](https://avatars.githubusercontent.com/u/210297?v=4)](https://github.com/siebrand "siebrand (1 commits)")[![legoktm](https://avatars.githubusercontent.com/u/81392?v=4)](https://github.com/legoktm "legoktm (1 commits)")[![neoncitylights](https://avatars.githubusercontent.com/u/4723983?v=4)](https://github.com/neoncitylights "neoncitylights (1 commits)")[![raymondde](https://avatars.githubusercontent.com/u/4243486?v=4)](https://github.com/raymondde "raymondde (1 commits)")[![Ladsgroup](https://avatars.githubusercontent.com/u/5351225?v=4)](https://github.com/Ladsgroup "Ladsgroup (1 commits)")

### Embed Badge

![Health badge](/badges/wikifab-google-analytics-metrics/health.svg)

```
[![Health](https://phpackages.com/badges/wikifab-google-analytics-metrics/health.svg)](https://phpackages.com/packages/wikifab-google-analytics-metrics)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
