Support Home > SDK Integration > SDK – KochavaTracker Xamarin

SDK – KochavaTracker Xamarin


KochavaTracker Xamarin

A lightweight and easy to integrate SDK written in C# that wraps the native Android and iOS SDKs, providing first-class integration with Free App Analytics’ installation attribution and analytics platform.

Our Xamarin SDK supports all Mono frameworks including MonoGame.

Please use our Windows SDK directly if targeting a windows platform.



  • Android
  • iOS



  • Android API 14
  • NOTE: Google has deprecated their legacy Play Install Referrer API which utilized a broadcast receiver. The updated version requires that the library be added to replace it. Our native Android SDK Integration documentation describes this change in more detail.

  • Xcode 8.0


  1. Add the SDK into your project.
    (Release Notes)


    Directly Importing the DLL:

    The SDK can also be included by downloading the DLL from the version badge above and including it directly. This must be done individually for iOS and Android in their respective projects.

    1. Right click the References folder in your project and Click Edit References.
    2. Select the .Net Assembly tab and Click Browse.
    3. Locate and Select the KochavaXamarin DLL and import it.


  2. Add Dependencies.
    The following items are for Android only. If using iOS only proceed to Step 3.

    1. (Required) Add the Google Play Services Analytics Component:
    2. (Optional) To gather location add the Google Play Services Location Component: and check ACCESS_COARSE_LOCATION and/or ACCESS_FINE_LOCATION.
    3. (Optional) To gather email accounts check GET_ACCOUNTS.
    4. (Optional) To gather paired and connected bluetooth devices check BLUETOOTH.


  3. Configure a Tracker


    • To configure it, first create a trackerParametersDictionary, and then perform the configuration using the designated configuration instance method configure(withParametersDictionary:delegate:). It is recommended that you call this in your UIApplicationDelegate instance method application(_:didFinishLaunchingWithOptions:).

    • To configure the Tracker, first create a Tracker.Configuration object, and then perform the configuration using the configuration method Tracker.configure(Com.Kochava.Base.Tracker.Configuration). It is recommended that you call this in your Application.OnCreate method.

Using the SDK

Sending Events:

More than basic analytics, the events you send to Free App Analytics are associated with your install attribution data, so that you can understand how the users who came to you through a particular ad went on to use the various features within your app.


  • For more information, refer to Class – KochavaEvent.

  • For more information, refer to Tracker.Event.

Setting Identity Link:

You can link additional identifying information with a install, where it can be integrated with your analytics. For more information see:

Getting Attribution:

You can retrieve Free App Analytics’ attribution information within your app. For more information see:

Getting the Device ID:

You can get the unique device identifier used by the tracker. For more information see:

Adjusting the Log Level:

You can specify the types of entries which the tracker prints to the log. For more information see:

Intelligent Consent Management:

When intelligent consent management is enabled and configured within your Free App Analytics dashboard, the SDK will indicate when the user should be prompted for consent. It will also not gather, persist, or transmit data which requires consent unless consent has been granted. For more information see:

See Also

The Xamarin SDK is a thin wrapper over the native Android and iOS SDKs. The reference documentation for those platforms is available for more advanced usage.



Last Modified: Dec 11, 2019 at 4:19 pm