SDK for Android to measure your apps with Piwik
Clone or download

Piwik SDK for Android

Build Status Download Coverage Status

Welcome to the Piwik Tracking SDK for Android. This library helps you send analytics data from Android apps to Piwik instances.



For the not so quick start, see here or look at our demo app

  • Setup Piwik on your server.
  • Include the library in your app modules build.gradle file
    implementation 'org.piwik.sdk:piwik-sdk:<latest-version>'
  • Initialize your Tracker either by extending our PiwikApplication class or storing an instance yourself:
public class YourApplication extends Application {
    private Tracker tracker;
    public synchronized Tracker getTracker() {
        if (tracker == null) tracker = Piwik.getInstance(this).newTracker(new TrackerConfig("http://domain.tld/piwik.php", 1));
        return tracker;
  • The TrackHelper class is the easiest way to submit events to your tracker:
// Get the `Tracker` you want to use
Tracker tracker = ((PiwikApplication) getApplication()).getTracker();
// Track a screen view
// Monitor your app installs


Android SDK for Piwik is released under the BSD-3 Clause license, see LICENSE.