To backup Matomo:

  1. Regularly backup the Mysql database containing Matomo (Piwik) tables (eg. using an existing Mysql backup script)
  2. Regularly backup the file piwik/config/config.ini.php
  3. Regularly backup any Plugin you may have installed from the Marketplace, stored in piwik/plugins/* folder

To restore a Matomo backup:

  1. Import the Mysql backup data in a new Mysql database you have created
  2. Download the latest version of Matomo, unzip and upload
  3. Copy the file config.ini.php from the backup into your new piwik setup. You might have to edit the database connection settings in the file if they have changed.
  4. Copy any Third party Plugin installed from the Marketplace from the backup (or download from the marketplace the latest version of these plugins) and copy them into your new piwik setup.
  5. Visit Matomo and check that everything is working correctly!
Previous FAQ: How do I backup my MySQL database?