Extension Matomo


Extension Basics

Title
Matomo
Name
ckanext-matomo
Type
Public extension
Description
The **Matomo** extension for CKAN provides web analytics integration using the Matomo platform. Thi
CKAN versions
Download-Url (zip)
Last commit
5 months ago (2025-08-11 10:02:19)
Url to repo
Category
Visualization & Analytics


Background Infos

Description (long)
Show details

ckanext-matomo - Matomo analytics extension

Tests

codecov

Adds matomo analytics tracking to ckan. By default only posts tracking data to configured matomo instance.


Requirements

Compatibility with core CKAN versions:

CKAN version Compatible?
2.8 not tested
2.9 yes
2.10 yes

Installation

To install ckanext-matomo:

  1. Activate your CKAN virtual environment, for example:
. /usr/lib/ckan/default/bin/activate
  1. Clone the source and install it on the virtualenv
    git clone https://github.com/vrk-kpa/ckanext-matomo.git
    cd ckanext-matomo
    pip install -e .
    pip install -r requirements.txt
  1. Add matomo to the ckan.plugins setting in your CKAN config file (by default the config file is located at /etc/ckan/default/ckan.ini).

  2. Initialize database for local matomo data

     ckan -c ckan.ini db upgrade -p matomo
  1. Restart CKAN. For example if you’ve deployed CKAN with uWSGI on Ubuntu:
     sudo supervisorctl restart all

Config Settings

# The domain used for matomo analytics
ckanext.matomo.domain = http://example.com/

# The site id used in matomo
ckanext.matomo.site_id = 1

# The domain where matomo script is downloaded
# (optional, default ckanext.matomo.domain)
ckanext.matomo.script_domain

# matomo api token, required for posting api events and downloading analytics
ckanext.matomo.token_auth = <your token here>

# To track api events, set to true
ckanext.matomo.track_api = true

# To track downloads, s
Version
Version release date
(not set)
Contact name
Finnish Digital Agency
Contakt email
Contact Url
(not set)


Installation Guide

Configuration hints
Plugins to configure (ckan.ini)
matomo
CKAN Settings (ckan.ini)
# ckanext.matomo.domain = http://example.com/
# ckanext.matomo.site_id = 1
# ckanext.matomo.token_auth = <your token here>
# ckanext.matomo.track_api = true
# ckanext.matoto.track_downloads = true
# ckanext.matomo.token_auth = <your token here>
DB migration to be executed
upgrade
<< back to Extensions