Note: If you are not already using Custom Variables to measure your custom data, we recommend to use the Custom Dimensions feature instead. There are many advantages of Custom Dimensions over Custom variables. Custom variables will be deprecated in the future.

By default Matomo (Piwik) provides five custom variables. You may configure Matomo to track more custom variables. New custom variable slots will be created in both the ‘visit’ scope and ‘page’ scope.

First you need to be able to connect to the server running Matomo over SSH, so you can type commands to the Matomo console. To increase the custom variables slots from 5 to 10, type in the terminal:

$ cd /path/to/piwik
$ ./console customvariables:info

  Your Matomo is configured for 5 custom variables. 

$ ./console customvariables:set-max-custom-variables 10

You can now track up to 10 custom variables in the visit and page scope. Enjoy!

Note: this console command will update your Matomo Database schema and will add columns in several tables in order to track more custom variables.

Previous FAQ: How many Custom Variables can I set to visitors and/or page views?