This page explains how to install Piwik on your web server and start tracking your site web analytics. If you prefer to watch a video tutorial, click here: How to Setup Piwik Analytics [Video]
Before you get started, ensure that you have the following:
- A web server, shared hosting or dedicated server. If you do not have a web server or shared host to install Piwik on, you can get a pre-installed Piwik in minutes. See our top Piwik web hosts.
- Access to your web server (via shell or FTP)
- A FTP Client (if you are installing Piwik on a remote server)
Start the Installation
Check to make sure that your web host meets the minimum requirements to run Piwik.
If your web host offers one-click software (Softaculous or Installatron for example), you can install Piwik in one click. Otherwise, follow these steps:
- Download the latest release Piwik from here
- Unzip the zip file to a folder on your hard drive. This will create a “piwik” folder containing the files and directories.
- Open your FTP client and upload the Piwik files in ‘binary mode’ to the desired location on your web server. All files can be uploaded to a “analytics” sub-directory in your public www folder, for example http://yourdomain.org/analytics/ or you could setup Piwik in its own subdomain and upload all the files at http://analytics.example.org/If you have SSH access to your server, you can use it instead of FTP as it is much faster: run
wget http://builds.piwik.org/piwik.zip && unzip piwik.zip
When Piwik is uploaded you can move on to the next step!
The 5-minute Piwik Installation
Open your web browser and navigate to the URL to which you uploaded Piwik. If everything is uploaded correctly, you should see the Piwik Installation Welcome Screen. If there are any problems, Piwik will identify them and help you out with a solution.
The Welcome Screen
Time to get started with the point-and-click installation! Click Next »
Piwik will check to make sure that your server meets the Piwik requirements. If everything is okay, you’ll see a long list like this:
If there is a problem, Piwik will identify it and tell you how to solve it, as in this example:
When all the requirements are met, click *Next **»*
MySQL Database Setup
You should already have set up your MySQL database. If you do not have the database information, you may need to ask your web host or technical staff.
Security note: for added security, we recommend that you install Piwik in its own MySQL database and specify a username and password for a user that only has access to that database.
Once you have filled in the form, click Next »
Piwik will add the necessary tables to your database:
Click* Next »*
The super user is the user that you create when you install Piwik. This user has the highest permissions. Choose your username and password:
Do not lose this information; it is the only way for you to log in to Piwik for the first time. There is only one super user in each Piwik installation. The super user can perform administrative tasks such as adding new websites to monitor, adding users, changing user permissions, and enabling and disabling plugins.
By default the super user will be signed up for upgrade and security alerts, as well as for community updates. Uncheck these boxes if you do not want to receive these emails.
Fill in the information and click Next »
Set up Your First Website
Enter the name and URL of the first website you want to track. You can add more websites once the installation is complete.
Click Next »
If you use a CMS such as WordPress, Drupal or Joomla!, you can use an add-on, extension or plugin to make sure this tag appears where it needs to.
Otherwise you will need to insert your tracking tag manually.
When you have copied your tracking tag click Next »
Piwik is installed and ready to track your visitors. As soon as visitors start arriving, Piwik will be keeping track of their data. Piwik reports are generated in real time, so you should see data in your Piwik dashboard straight away.
Click Continue to Piwik » and log in to your dashboard!
If you want to give other users access to Piwik, monitor more than one website, rebrand Piwik or install third party plugins, you will need to use the Settings page. The link is at the top right hand side of your dashboard.
When you have finished configuring Piwik, you can set more restrictive permissions (ie. read only) to the “piwik/config/” folder. Piwik will always write its data inside the “piwik/tmp/” folder, so this is the only folder that requires write permissions.
Medium and High-Traffic Websites: Setup an automated task (cron) to process reports
If your website is a medium or high-traffic website (more than a few hundred visits per day), we highly recommend to set up auto-archiving cron task so that Piwik calculates your reports periodically. When the cron is setup and the timeout value increased, Piwik dashboard will load very quickly as the reports will be pre-processed by the archive.php cron task.
If you do not setup the cron, Piwik will recalculate your statistics every time you visit a Piwik report, which will slow Piwik down and increase the load on your database.
Instructions for setting up auto-archiving can be found on the Piwik website at How to setup Piwik auto-archiving.
Updates, Recommended Server Configuration, and More
Check also the Piwik Installation, Update & Optimization documentation for more information.