Enabling Install Attribution and Re-marketing

To enable install attribution or re-marketing  you will need the xtremepush SDK to collect the Advertising identifiers on Android and iOS details of how to enable this on Android and iOS below:



On Android you need to add play services ad support by adding following dependency to build.gradle:

compile 'com.google.android.gms:play­-services-ads:10.2.0'

And you will need to update your Android Manifest by adding the following code to AndroidManifest.xml (where YOUR_PACKAGE_NAME is replaced with your app’s package name):

<receiver android:name="ie.imobile.extremepush.receivers.ReferrerReceiver"> 
  <action android:name="com.android.vending.INSTALL_REFERRER" />
  <category android:name="YOUR_PACKAGE_NAME" /> 

 And you also need to enable attributions when initialising the xtremepush SDK in your main activity. Add the following code when initialising push connector:


For example:

new PushConnector.Builder(AppId, GoogleProjectID)


On iOS you will need to use the Adsupport.framework:



Code Changes


Add the following code when initialising xpush library in your app delegate:

[XPush setAttributionsEnabled: YES] ;

This should be inserted before the following code:

[XPush applicationDidFinishLaunchingWithOptions: launchOptions];


For Swift you will need to add the following method in didFinishLaunchingWithOptions:


Note: Prior to iOS SDK version 3.3 (ref i-09012017) to use attributions it was necessary to replace your SDK with a version of the xtremepush library with IDFA collection support.  Both libXPush.a and XPush.h needed to be updated. This is no longer the case but this version of the SDK is still available on the iOS SDK Downloads page if needed. 


Have more questions? Submit a request


Article is closed for comments.