{"id":40608,"date":"2022-05-02T12:30:33","date_gmt":"2022-05-02T17:30:33","guid":{"rendered":"https:\/\/www.rosehosting.com\/blog\/?p=40608"},"modified":"2025-12-24T08:31:27","modified_gmt":"2025-12-24T14:31:27","slug":"how-to-install-matomo-web-analytics-on-ubuntu-20-04","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/","title":{"rendered":"How to Install Matomo Web Analytics on Ubuntu 20.04"},"content":{"rendered":"<div id=\"bsf_rt_marker\"><\/div>\n<p><p><img decoding=\"async\" width=\"742\" height=\"372\" class=\"size-full wp-image-41219 alignnone\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg\" alt=\"how to install matomo web analytics on ubuntu 20.04\" srcset=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg 742w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04-300x150.jpg 300w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04-150x75.jpg 150w\" sizes=\"(max-width: 742px) 100vw, 742px\" \/><\/p><br><p>Matomo (formerly known as Piwik) is a free and open-source web analytics application developed in PHP to be the ultimate alternative to Google Analytics. Matomo can be used to track online visits to one or more websites and displays reports on these visits for analysis.<\/p>In this tutorial, we will show you how to install Matomo Web Analytics on your <a href=\"https:\/\/www.rosehosting.com\/ubuntu-hosting.html\">Ubuntu 20.04 VPS<\/a>.<\/p>\n\n\n\n<!--more-->\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-transparent ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-69e6cf8513965\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"ez-toc-cssicon\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-69e6cf8513965\"  aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Prerequisites\" >Prerequisites<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-1-Log-in-via-SSH-and-update-the-system\" >Step 1. Log in via SSH and update the system<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-2-Install-Apache-Webserver\" >Step 2: Install Apache Webserver<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-3-Install-PHP-with-required-extensions\" >Step 3: Install PHP with required extensions<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-4-Install-MariaDB-and-create-a-database-for-Matomo\" >Step 4: Install MariaDB and create a database for Matomo<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-5-Download-Matomo-on-Ubuntu-2004\" >Step 5: Download Matomo on Ubuntu 20.04<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-6-Create-an-Apache-configuration-file\" >Step 6: Create an Apache configuration file<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-7-Install-an-SSL-certificate\" >Step 7. Install an SSL certificate<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#Step-8-Installing-Matomo-Using-the-Web-Interface\" >Step 8: Installing Matomo Using the Web Interface<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\" id=\"h-prerequisites\"><span class=\"ez-toc-section\" id=\"Prerequisites\"><\/span>Prerequisites<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Ubuntu 20.04 VPS<\/li>\n\n\n\n<li>SSH root access or a regular system user with sudo privileges<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-step-1-log-in-via-ssh-and-update-the-system\"><span class=\"ez-toc-section\" id=\"Step-1-Log-in-via-SSH-and-update-the-system\"><\/span>Step 1. Log in via SSH and update the system<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Log in to your Ubuntu 20.04 VPS with SSH as a root user:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">ssh root@IP_Address -p Port_number<\/pre>\n\n\n\n<p>Replace \u201c<strong>IP_Address<\/strong>\u201d and \u201c<strong>Port_Number<\/strong>\u201d with your server\u2019s IP address and SSH port.<\/p>\n\n\n\n<p>Now, run the following command to update all installed packages to the latest available version.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">apt update &amp;&amp; sudo apt upgrade<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-step-2-install-apache-webserver\"><span class=\"ez-toc-section\" id=\"Step-2-Install-Apache-Webserver\"><\/span>Step 2: Install Apache Webserver<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Execute the following command to install the Apache web server:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">apt install apache2<\/pre>\n\n\n\n<p>To start Apache and to enable it to auto-start on server boot, run these commands:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">systemctl start apache2\nsystemctl enable apache2<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-step-3-install-php-with-required-extensions\"><span class=\"ez-toc-section\" id=\"Step-3-Install-PHP-with-required-extensions\"><\/span>Step 3: Install PHP with required extensions<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>To install PHP and the required PHP extensions, run the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">apt install php php-cli libapache2-mod-php php-common php-curl php-gd php-mbstring php-mysql php-xml php-intl php-zip<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-step-4-install-mariadb-and-create-a-database-for-matomo\"><span class=\"ez-toc-section\" id=\"Step-4-Install-MariaDB-and-create-a-database-for-Matomo\"><\/span>Step 4: Install MariaDB and create a database for Matomo<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Matomo needs a database server, and it can be installed by running the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">apt install mariadb-server<\/pre>\n\n\n\n<p>Once the MariaDB server has been installed, log in to the MariaDB shell as the root user and create a database and user for Matomo:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mysql -u root -p<\/pre>\n\n\n\n<pre class=\"wp-block-preformatted\">MariaDB [(none)]&gt; CREATE DATABASE matomodb;\nMariaDB [(none)]&gt; GRANT ALL PRIVILEGES ON matomodb.* TO 'matomouser'@'localhost' IDENTIFIED BY 'Passw0rd';\nMariaDB [(none)]&gt; FLUSH PRIVILEGES;\nMariaDB [(none)]&gt; EXIT;<\/pre>\n\n\n\n<p>Don\u2019t forget to replace <strong>\u2018Passw0rd\u2019<\/strong> with an actual strong password.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-step-5-download-matomo-on-ubuntu-20-04\"><span class=\"ez-toc-section\" id=\"Step-5-Download-Matomo-on-Ubuntu-2004\"><\/span>Step 5: Download Matomo on Ubuntu 20.04<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Download the latest version of Matomo from the official website on your server:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wget https:\/\/builds.matomo.org\/matomo.zip<\/pre>\n\n\n\n<p>Once downloaded, unzip the downloaded file with the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">unzip matomo.zip -d \/var\/www\/html\/<\/pre>\n\n\n\n<p>Then change the ownership of Matomo to www-data:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">chown -R www-data:www-data \/var\/www\/html\/matomo\/<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-6-Create-an-Apache-configuration-file\"><\/span>Step 6: Create an Apache configuration file<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>To create a new configuration file for Matomo, we can create a new <a href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-and-configure-apache-and-php-on-rosehosting-cloud-paas\/\">Apache configuration<\/a> file:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">nano \/etc\/apache2\/sites-available\/matomo.conf<\/pre>\n\n\n\n<p>A basic Apache configuration file looks similar to this:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"> &lt;VirtualHost *:80&gt;\n    ServerAdmin admin@your_domain.com\n     DocumentRoot \/var\/www\/html\/matomo\n     ServerName your_domain.com\n     ServerAlias www.your_domain.com\n     \n     &lt;Directory \/var\/www\/html\/matomo\/&gt;\n          Options FollowSymlinks\n          AllowOverride All\n          Require all granted\n     &lt;\/Directory&gt;\n\n     ErrorLog ${APACHE_LOG_DIR}\/matomo_error.log\n     CustomLog ${APACHE_LOG_DIR}\/matomo_access.log combined\n&lt;\/VirtualHost&gt;\n<\/pre>\n\n\n\n<p>Don\u2019t forget to change the domain name next to ServerAdmin and ServerName (<code>your_domain.com<\/code>) in order to make it work with your unique registered domain name.<\/p>\n\n\n\n<p>Save and close the file, then activate the Matomo virtual host with the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">a2ensite matomo.conf<\/pre>\n\n\n\n<p>Restart the Apache service, and you are ready:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">systemctl restart apache2<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-step-7-install-an-ssl-certificate\"><span class=\"ez-toc-section\" id=\"Step-7-Install-an-SSL-certificate\"><\/span>Step 7. Install an SSL certificate<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>In this step, we will enable SSL for Matomo by using a free Let\u2019s Encrypt SSL certificate.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">apt install python3-certbot-apache -y<\/pre>\n\n\n\n<p>Once Certbot is installed, we are ready to install the certificate for the domain:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">certbot --apache<\/pre>\n\n\n\n<p>After the successful installation, the following similar message will be received:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">- Congratulations! Your certificate and chain have been saved at:\n\/etc\/letsencrypt\/live\/your_domain.com\/fullchain.pem\nYour key file has been saved at:\n\/etc\/letsencrypt\/live\/your_domain.com\/privkey.pem<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-8-Installing-Matomo-Using-the-Web-Interface\"><\/span>Step 8: Installing Matomo Using the Web Interface<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>To run the web installation wizard, go to <strong>https:\/\/your_domain.com<\/strong> and you will be redirected to the Matomo welcome page. Click on the <strong>&#8220;Next&#8221;<\/strong> button:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/install-matomo-web-analytics-on-ubuntu-20.04.webp\" alt=\"install matomo web analytics on ubuntu 20.04\" class=\"wp-image-40610\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>You will see a &#8220;System Check&#8221; page. If everything is marked with a green checkmark, click on the <strong>&#8220;Next&#8221;<\/strong> button to proceed to the next step:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/install-matomo-on-ubuntu-20.04.webp\" alt=\"install matomo on ubuntu 20.04\" class=\"wp-image-40611\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>You should get to the Database Setup page. Use database credentials configured earlier:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/install-matomo-web-analytics-on-ubuntu.webp\" alt=\"install matomo web analytics on ubuntu\" class=\"wp-image-40612\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>The creation of the Tables should return the &#8220;<strong>Tables created with success!<\/strong>&#8221; message:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/install-matomo-web-analytics-ubuntu-20.04.webp\" alt=\"install matomo web analytics ubuntu 20.04\" class=\"wp-image-40613\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Next, you have to create&nbsp;a&nbsp;<strong>Super User<\/strong>. Provide username, password, and email address.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/matomo-web-analytics-on-ubuntu-20.04.webp\" alt=\"matomo web analytics on ubuntu 20.04\" class=\"wp-image-40614\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Now, provide the site name, website URL, and then click on the <strong>Next<\/strong> button.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/matomo-web-analytics-on-ubuntu.webp\" alt=\"matomo web analytics on ubuntu\" class=\"wp-image-40615\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>You should see the Tracking code for the Matomo site on the following page:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/matomo-analytics-on-ubuntu-20.04.webp\" alt=\"matomo analytics on ubuntu 20.04\" class=\"wp-image-40616\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Next, you should see that the Matomo installation has been completed. Click on the <strong>CONTINUE TO MATOMO<\/strong> button.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/matomo-on-ubuntu-20.04.webp\" alt=\"matomo on ubuntu 20.04\" class=\"wp-image-40617\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Now, you can log in to the Matomo administration back-end:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/install-matomo-analytics-on-ubuntu-20.04.webp\" alt=\"install matomo analytics on ubuntu 20.04\" class=\"wp-image-40618\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>You should see the Matomo Dashboard, and you can add more websites, check the stats, etc.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/matomo-web-analytics-ubuntu-20.04.webp\" alt=\"matomo web analytics ubuntu 20.04\" class=\"wp-image-40619\"\/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>That is it. The Matomo installation is now complete. Of course, you don\u2019t have to do any of this if you use one of our <a href=\"https:\/\/www.rosehosting.com\/matomo-analytics-hosting\/\" target=\"_blank\" rel=\"noreferrer noopener\">Matomo Analytics Hosting<\/a> services, in which case you can simply ask our expert Linux admins to install <strong>Matomo<\/strong> for you. They are available 24\u00d77 and will take care of your request immediately.<\/p>\n\n\n\n<p>If you liked this post on how to install Matomo Web Analytics on Ubuntu 20.04, please share it with your friends or leave a comment below.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Matomo (formerly known as Piwik) is a free and open-source web analytics application developed in PHP to be the ultimate &#8230; <\/p>\n<p class=\"read-more-container\"><a title=\"How to Install Matomo Web Analytics on Ubuntu 20.04\" class=\"read-more button\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#more-40608\" aria-label=\"Read more about How to Install Matomo Web Analytics on Ubuntu 20.04\">Read More<\/a><\/p>\n","protected":false},"author":4,"featured_media":41219,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13,1698],"tags":[1716,1839,1283],"class_list":["post-40608","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tutorials","category-ubuntu","tag-matomo","tag-ubuntu-20-04","tag-web-analytics","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-33"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.4 (Yoast SEO v27.4) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>How to Install Matomo Web Analytics on Ubuntu 20.04 | RoseHosting<\/title>\n<meta name=\"description\" content=\"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let&#039;s dive right in!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Install Matomo Web Analytics on Ubuntu 20.04\" \/>\n<meta property=\"og:description\" content=\"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let&#039;s dive right in!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/\" \/>\n<meta property=\"og:site_name\" content=\"RoseHosting\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/RoseHosting\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/rosehosting.helpdesk\" \/>\n<meta property=\"article:published_time\" content=\"2022-05-02T17:30:33+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-12-24T14:31:27+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"742\" \/>\n\t<meta property=\"og:image:height\" content=\"372\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Jeff Wilson\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:description\" content=\"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let&#039;s dive right in!\" \/>\n<meta name=\"twitter:creator\" content=\"@rosehosting\" \/>\n<meta name=\"twitter:site\" content=\"@rosehosting\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jeff Wilson\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/\"},\"author\":{\"name\":\"Jeff Wilson\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/person\\\/7ce77a842fa6a9a7f8efa186f2353713\"},\"headline\":\"How to Install Matomo Web Analytics on Ubuntu 20.04\",\"datePublished\":\"2022-05-02T17:30:33+00:00\",\"dateModified\":\"2025-12-24T14:31:27+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/\"},\"wordCount\":662,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/04\\\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg\",\"keywords\":[\"matomo\",\"Ubuntu 20.04\",\"web analytics\"],\"articleSection\":[\"Tutorials\",\"Ubuntu\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/\",\"name\":\"How to Install Matomo Web Analytics on Ubuntu 20.04 | RoseHosting\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/04\\\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg\",\"datePublished\":\"2022-05-02T17:30:33+00:00\",\"dateModified\":\"2025-12-24T14:31:27+00:00\",\"description\":\"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let's dive right in!\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/04\\\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg\",\"contentUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/04\\\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg\",\"width\":742,\"height\":372,\"caption\":\"how to install matomo web analytics on ubuntu 20.04\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Install Matomo Web Analytics on Ubuntu 20.04\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/\",\"name\":\"RoseHosting.com\",\"description\":\"Premium Linux Tutorials Since 2001\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#organization\",\"name\":\"RoseHosting\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/03\\\/android-chrome-192x192-1.png\",\"contentUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/03\\\/android-chrome-192x192-1.png\",\"width\":192,\"height\":192,\"caption\":\"RoseHosting\"},\"image\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/RoseHosting\",\"https:\\\/\\\/x.com\\\/rosehosting\",\"https:\\\/\\\/www.linkedin.com\\\/in\\\/rosehosting\\\/\"],\"description\":\"RoseHosting is a leading Linux hosting provider, serving thousands of clients world-wide since 2001.\",\"email\":\"info@rosehosting.com\",\"telephone\":\"(314) 275-0414\",\"legalName\":\"Rose Web Services LLC\",\"foundingDate\":\"2001-04-02\",\"numberOfEmployees\":{\"@type\":\"QuantitativeValue\",\"minValue\":\"11\",\"maxValue\":\"50\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/person\\\/7ce77a842fa6a9a7f8efa186f2353713\",\"name\":\"Jeff Wilson\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"caption\":\"Jeff Wilson\"},\"description\":\"An experienced Linux veteran with many years of experience. Helping other Linux admins with frequent Linux and business-related blog posts on the RoseHosting blog. Techie by choice. Loving nature and travel. Happily married and father of two lovely children.\",\"sameAs\":[\"https:\\\/\\\/www.rosehosting.com\",\"https:\\\/\\\/www.facebook.com\\\/rosehosting.helpdesk\"],\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/author\\\/jwilson\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"How to Install Matomo Web Analytics on Ubuntu 20.04 | RoseHosting","description":"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let's dive right in!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/","og_locale":"en_US","og_type":"article","og_title":"How to Install Matomo Web Analytics on Ubuntu 20.04","og_description":"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let's dive right in!","og_url":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/","og_site_name":"RoseHosting","article_publisher":"https:\/\/www.facebook.com\/RoseHosting","article_author":"https:\/\/www.facebook.com\/rosehosting.helpdesk","article_published_time":"2022-05-02T17:30:33+00:00","article_modified_time":"2025-12-24T14:31:27+00:00","og_image":[{"width":742,"height":372,"url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg","type":"image\/jpeg"}],"author":"Jeff Wilson","twitter_card":"summary_large_image","twitter_description":"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let's dive right in!","twitter_creator":"@rosehosting","twitter_site":"@rosehosting","twitter_misc":{"Written by":"Jeff Wilson","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#article","isPartOf":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/"},"author":{"name":"Jeff Wilson","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713"},"headline":"How to Install Matomo Web Analytics on Ubuntu 20.04","datePublished":"2022-05-02T17:30:33+00:00","dateModified":"2025-12-24T14:31:27+00:00","mainEntityOfPage":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/"},"wordCount":662,"commentCount":0,"publisher":{"@id":"https:\/\/www.rosehosting.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#primaryimage"},"thumbnailUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg","keywords":["matomo","Ubuntu 20.04","web analytics"],"articleSection":["Tutorials","Ubuntu"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/","url":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/","name":"How to Install Matomo Web Analytics on Ubuntu 20.04 | RoseHosting","isPartOf":{"@id":"https:\/\/www.rosehosting.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#primaryimage"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#primaryimage"},"thumbnailUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg","datePublished":"2022-05-02T17:30:33+00:00","dateModified":"2025-12-24T14:31:27+00:00","description":"In this tutorial, we will show you how to install Matomo Web Analytics on Ubuntu 20.04. Let's dive right in!","breadcrumb":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#primaryimage","url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg","contentUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/04\/how-to-install-matomo-web-analytics-on-ubuntu-20.04.jpg","width":742,"height":372,"caption":"how to install matomo web analytics on ubuntu 20.04"},{"@type":"BreadcrumbList","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-matomo-web-analytics-on-ubuntu-20-04\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.rosehosting.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Install Matomo Web Analytics on Ubuntu 20.04"}]},{"@type":"WebSite","@id":"https:\/\/www.rosehosting.com\/blog\/#website","url":"https:\/\/www.rosehosting.com\/blog\/","name":"RoseHosting.com","description":"Premium Linux Tutorials Since 2001","publisher":{"@id":"https:\/\/www.rosehosting.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.rosehosting.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.rosehosting.com\/blog\/#organization","name":"RoseHosting","url":"https:\/\/www.rosehosting.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png","contentUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png","width":192,"height":192,"caption":"RoseHosting"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/RoseHosting","https:\/\/x.com\/rosehosting","https:\/\/www.linkedin.com\/in\/rosehosting\/"],"description":"RoseHosting is a leading Linux hosting provider, serving thousands of clients world-wide since 2001.","email":"info@rosehosting.com","telephone":"(314) 275-0414","legalName":"Rose Web Services LLC","foundingDate":"2001-04-02","numberOfEmployees":{"@type":"QuantitativeValue","minValue":"11","maxValue":"50"}},{"@type":"Person","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713","name":"Jeff Wilson","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","caption":"Jeff Wilson"},"description":"An experienced Linux veteran with many years of experience. Helping other Linux admins with frequent Linux and business-related blog posts on the RoseHosting blog. Techie by choice. Loving nature and travel. Happily married and father of two lovely children.","sameAs":["https:\/\/www.rosehosting.com","https:\/\/www.facebook.com\/rosehosting.helpdesk"],"url":"https:\/\/www.rosehosting.com\/blog\/author\/jwilson\/"}]}},"_links":{"self":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/40608","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/comments?post=40608"}],"version-history":[{"count":12,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/40608\/revisions"}],"predecessor-version":[{"id":51473,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/40608\/revisions\/51473"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/media\/41219"}],"wp:attachment":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/media?parent=40608"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/categories?post=40608"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/tags?post=40608"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}