Updated: 29 September 2026 · Applies to: Matomo 5.14 on Fedora 44 (Apache 2.4, PHP 8.5, MariaDB 11.8)
This guide installs Matomo on Fedora 44 with Apache, PHP-FPM and MariaDB. Fedora 29, which an older version of this article covered, is long out of support, and each Fedora release is supported for only about 13 months, so for a long-running analytics server AlmaLinux or Rocky Linux is usually the better choice (see how to install Matomo on AlmaLinux and Rocky Linux). We tested the steps on Fedora 44 on 29 September 2026: Matomo 5.14.0 passed all required checks of its installer with PHP 8.5 and MariaDB 11.8.
Matomo (formerly Piwik) is free, open-source web analytics that you host yourself: visitor data stays on your own server instead of going to a third party, which helps with privacy rules such as the GDPR. The current release is Matomo 5.14. Matomo 6, in beta at the time of writing, will need PHP 8.1 or newer and MariaDB 10.6 or newer (or MySQL 8.0); the steps below already meet that.
Install Apache, PHP and MariaDB
dnf upgrade dnf install httpd mariadb-server php php-fpm php-mysqlnd php-xml php-mbstring php-gd php-intl php-pecl-zip unzip systemctl enable --now httpd mariadb php-fpm firewall-cmd --permanent --add-service=http --add-service=https && firewall-cmd --reload
Create the database
Run mariadb-secure-installation once to remove test data, then create a database and user for Matomo:
mariadb CREATE DATABASE matomo CHARACTER SET utf8mb4; CREATE USER 'matomo'@'localhost' IDENTIFIED BY 'a-long-random-password'; GRANT ALL PRIVILEGES ON matomo.* TO 'matomo'@'localhost'; FLUSH PRIVILEGES; EXIT;
Download Matomo
cd /var/www curl -LO https://builds.matomo.org/matomo.zip unzip -q matomo.zip && rm matomo.zip chown -R apache:apache /var/www/matomo
This always fetches the latest stable release into /var/www/matomo.
Create the Apache site
Create /etc/httpd/conf.d/matomo.conf:
<VirtualHost *:80>
ServerName analytics.example.com
DocumentRoot /var/www/matomo
<Directory /var/www/matomo>
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
apachectl configtest && systemctl reload httpd
SELinux
SELinux is enforcing by default. Let Apache write to Matomo's configuration and temporary folders, and allow the outgoing connections Matomo uses for update checks:
semanage fcontext -a -t httpd_sys_rw_content_t "/var/www/matomo/(config|tmp)(/.*)?" restorecon -R /var/www/matomo setsebool -P httpd_can_network_connect 1
semanage is in the policycoreutils-python-utils package. Using localhost as the database server lets PHP connect through MariaDB's socket, which SELinux allows without further changes.
Add a free SSL certificate
dnf install certbot python3-certbot-apache mod_ssl certbot --apache -d analytics.example.com
Certbot renews the certificate automatically; test with certbot renew --dry-run.
Run the web installer
Open https://analytics.example.com and follow the steps:
- System check: all required items should be green. (Before HTTPS is set up, Matomo shows a warning that it recommends SSL.)
- Database setup: server
localhost, the usermatomowith its password, and the databasematomo. - Super user: your administrator login.
- Website: the name and address of the first site to track.
- Tracking code: copy the JavaScript snippet into every page of your site, before the closing
</head>tag. For WordPress, a Matomo plugin can add it for you.
Archive reports with cron
On busy sites, let a cron job prepare the reports instead of the browser. In Matomo, go to Administration > System > General settings and turn off Archive reports when viewed from the browser. Then create /etc/cron.d/matomo-archive:
5 * * * * apache /usr/bin/php /var/www/matomo/console core:archive --url=https://analytics.example.com/ > /dev/null
This prepares the reports every hour as the web server user.
Updates
Matomo announces new versions in its interface. Take a database backup (mariadb-dump matomo > matomo.sql), then update from Administration > System > Updates, or on the command line with sudo -u apache /usr/bin/php /var/www/matomo/console core:update.
Rather not run it yourself? Our Matomo VPS plans include a free Matomo installation with HTTPS and report archiving.
Official documentation: Matomo requirements, installing Matomo and setting up auto-archiving.