- Notifications
You must be signed in to change notification settings - Fork168
SDK for Android to measure your apps with Matomo. Works on Android phones, tablets, Fire TV sticks, and more!
License
NotificationsYou must be signed in to change notification settings
matomo-org/matomo-sdk-android
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
Welcome to theMatomo Tracking SDK for Android. This library helps you send analytics data from Android apps to Matomo instances. Until v4 this library was known asPiwik Tracking SDK for Android.
Features:
- Caching and offline support
- Graceful reconnection handling
- WIFI-only mode
- Thread-safe support for multiple trackers
- Support for custom connection implementations
- CompleteMatomo HTTP API support
- Checksum based app install/upgrade tracking
For the not so quick start,see here or look at ourdemo app
- Setup Matomo on your server.
- Include the library in your app modules
build.gradlefileviaJitPack
repositories { maven { url'https://jitpack.io' }}dependencies { implementation'com.github.matomo-org:matomo-sdk-android:<latest-version>'}- Now you need to initialize your
Tracker. It's recommended to store it as singleton. You can extendMatomoApplicationor create and store aTrackerinstance yourself:
importorg.matomo.sdk.TrackerBuilder;publicclassYourApplicationextendsApplication {privateTrackertracker;publicsynchronizedTrackergetTracker() {if (tracker ==null){tracker =TrackerBuilder.createDefault("http://domain.tld/matomo.php",1).build(Matomo.getInstance(this)); }returntracker; }}
- The
TrackHelperclass is the easiest way to submit events to your tracker:
// The `Tracker` instance from the previous stepTrackertracker = ((MatomoApplication)getApplication()).getTracker();// Track a screen viewTrackHelper.track().screen("/activity_main/activity_settings").title("Settings").with(tracker);// Monitor your app installsTrackHelper.track().download().with(tracker);
- Something not working? Checkhere.
Android SDK for Matomo is released under the BSD-3 Clause license, seeLICENSE.
About
SDK for Android to measure your apps with Matomo. Works on Android phones, tablets, Fire TV sticks, and more!
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
No packages published
Uh oh!
There was an error while loading.Please reload this page.