Migrating your Matomo instance

matomoYou may find that you need to move your Matomo instance to a new server or domain.  This article describes how to complete this process.

 


Copy

  1. You will need to create a dump of your MySQL database. I found it useful to dump a year at a time, to keep the file size manageable.
  2. You will need to copy all web site files.

 

Restore

Now you can import the database to the new server and copy all the files to the website root.

 

config.ini.php

To complete the migration you need to edit the config.ini.php and update any changes to the database credentials, and the domain name if you've changed that.

 

Javascript tags

Finally, if you have changed the domain name of your Matomo instance, you will need to update the tags on all website pages that are being monitored. This should be a straightforward task of editing a single plugin or custom theme content.

 

Alternative method

Matoma suggest an alternative method that includes a rebuild of your analytics site. I didn't find a rebuild necessary.

 

Thanks for visiting.