Table of Contents
ToggleServer-side tracking for mobile apps is often explained by copying the web version, and that is where the confusion starts. On the web you move browser tags into a server container. In an app there is no browser tag to move, because the SDK already runs on the device. So server-side tracking for mobile apps means something narrower: your own backend sends selected events to your measurement partner (MMP), to Meta or to Google Analytics, instead of the phone doing it.
This guide works from official documentation for AppsFlyer, Adjust, Branch, Meta’s Conversions API and Google’s Measurement Protocol, all checked on 2 November 2026. Where a vendor page leaves something out, I say so instead of guessing. The setup takes seven steps, and each one lists the exact fields and limits that tend to break it.
In a normal setup the MMP SDK reports installs, sessions and in-app events from the phone. A server-side setup adds a second path. When your backend learns something the phone may not report cleanly, it posts an event to the platform’s API. Typical cases are a payment your server confirmed, a subscription renewal that happens while the app is closed, a refund, or a lead that your sales team marks as qualified in a CRM.
The platform still has to know which device and which ad click the event belongs to, and that match depends on identifiers captured on the device earlier. If attribution basics are new to you, start with what mobile attribution is.
Adjust’s S2S events page states the split plainly: use the Adjust SDK to record installs, sessions and reattributions, and send only custom events through S2S. Treat that as a sound default for every platform, not only Adjust.
The cost is real, though. You now own identifier storage, retries, deduplication and consent handling. If your only goal is install attribution, this setup is not needed.
Use a simple rule for server-side tracking for mobile apps. Events your backend confirms go through the server. Events that describe what happened on the device stay in the SDK.
Pick one source for each event name and write it down. Meta documents deduplication using event_id together with event_name. The AppsFlyer, Adjust and Branch pages I read do not describe an equivalent rule for S2S events, so for those platforms a second source is a duplicate, not a backup.
Server-side tracking for mobile apps works only when each event carries the right identifier. Capture these in the app once, right after first launch, and save them against your own user ID.
appsflyer_id, generated at first install and available in the SDK. AppsFlyer lists it as mandatory, in the format 13 digits, a hyphen, then 19 digits. Also set the customer user ID in the app at install so raw data reports can map it to the device.idfa on iOS, gps_adid on Android) is required, and adid is recommended on iOS so devices can still be matched when the IDFA is unavailable.developer_identity, browser_fingerprint_id, or an iOS or Android device ID such as idfa, idfv, aaid or android_id.anon_id and the advertising ID as madid.app_instance_id, which Google says must come from the Firebase SDK, for example from FirebaseAnalytics.getAppInstanceId().A minimal record per user looks like this. Store the advertising ID only when the user allowed it.
{
"user_id": "user_48213",
"appsflyer_id": "1700000000000-1234567890123456789",
"app_instance_id": "FIREBASE_APP_INSTANCE_ID",
"meta_anon_id": "META_INSTALL_ID",
"att_status": "authorized",
"idfa": "ONLY_IF_ATT_AUTHORIZED"
}If you send an AppsFlyer event with no device identifier, AppsFlyer tries to enrich it from the install, except for IDFV. AppsFlyer also warns that missing identifiers can cause postback issues, audience rule failures and exclusion from incrementality measurement. Do not rely on the fallback.
AppsFlyer’s S2S in-app events reference uses a POST to https://api3.appsflyer.com/inappevent/{app_id}. The key must be the app’s S2S key, and an admin generates it. Send it in the authentication header described on that reference page.
{
"appsflyer_id": "1700000000000-1234567890123456789",
"eventName": "af_purchase",
"eventValue": "{\"af_revenue\":\"9.99\"}",
"eventCurrency": "USD",
"eventTime": "2026-11-02 09:30:00.000",
"customer_user_id": "user_48213",
"ip": "203.0.113.10",
"os": "17.5"
}These are the details that matter in practice when you wire up server-side tracking for mobile apps with AppsFlyer:
id123456789. Without the id, the request returns 200 and the event is not recorded.ip field accepts IPv4, and it feeds geo fields.att parameter for those devices, and a missing os on iOS is treated as 14.5.eventTime only inside a short window around the event day, with a cutoff at 02:00 UTC, and otherwise stamps the event with its arrival time. A late retry can therefore be recorded at the wrong time.appsflyer_id, an unparseable payload, or an app_id that does not match the token.If you are still on the older endpoint, AppsFlyer’s upgrade bulletin says the api2 URL moves to api3 with a new S2S key, and that the old endpoint will be blocked for affected apps after migration. For the SDK side, see the AppsFlyer setup guide. If you hit a 401, the AppsFlyer S2S 401 debug guide walks through the causes.
Adjust’s S2S events documentation accepts requests at https://s2s.adjust.com/event, by GET or POST. Each request carries a token generated in the Adjust dashboard when S2S security is on, and the examples send it in an Authorization: Bearer header. Test the token before you activate S2S authentication, because requests with a missing or wrong token are rejected.
curl -X POST "https://s2s.adjust.com/event" \
-H "Authorization: Bearer $ADJUST_S2S_TOKEN" \
-H "Content-Type: application/x-www-form-urlencoded" \
--data-urlencode "s2s=1" \
--data-urlencode "app_token=YOUR_APP_TOKEN" \
--data-urlencode "event_token=YOUR_EVENT_TOKEN" \
--data-urlencode "idfa=DEVICE_IDFA" \
--data-urlencode "adid=ADJUST_DEVICE_ID" \
--data-urlencode "ip_address=203.0.113.10" \
--data-urlencode "revenue=9.99" \
--data-urlencode "currency=USD"event_token, app_token and s2s=1. Parameter names are case sensitive.adid, an IPv4 ip_address, created_at_unix or created_at, and a URL-encoded user_agent.Branch’s events API overview uses POST https://api2.branch.io/v2/event/standard for standard events and https://api.branch.io/v2/event/custom for custom ones. The body needs branch_key, name and user_data, and the identifiers listed in Step 2. Branch is the most time-sensitive of the three for server-side tracking for mobile apps, because it only accepts events in real time.
{
"name": "PURCHASE",
"branch_key": "YOUR_BRANCH_KEY",
"user_data": {
"os": "iOS",
"idfa": "DEVICE_IDFA",
"os_version": "17.5",
"developer_identity": "user_48213"
}
}os_version is required for Facebook iOS campaigns, and anon_id is required for Facebook campaigns using AEM on iOS. If dma_eea is true, both dma_ad_personalization and dma_ad_user_data are required.This is where server-side tracking for mobile apps hits an Apple limit. Branch’s SKAdNetwork SDK page says Apple has no server-side API for reporting conversions, so the app itself must call Apple. Adjust documents a workaround: your server sends the event, Adjust calculates the conversion value and returns it in the S2S response, and the value waits until the next SDK request, when the SDK updates SKAdNetwork. A stored value is replaced only if the new one is higher, and the Adjust SDK is required.
Adjust also advises recording events through the SDK when the update has to reach Apple inside the same measurement window as the event. Branch adds that only one party should manage updateConversionValue calls. If SKAN matters for your app, read the SKAdNetwork setup guide before you move any event to the server.
Meta’s Conversions API for App Events page documents a POST to https://graph.facebook.com/{API_VERSION}/{DATASET_ID}/events. The app must be linked to the dataset first, in Events Manager, and each dataset can link only one app. The page does not require an MMP, so Meta is the easiest destination for server-side tracking for mobile apps if you have no partner in place.
{
"data": [
{
"event_name": "Purchase",
"event_time": 1793611800,
"event_id": "order_90210",
"action_source": "app",
"user_data": {
"anon_id": "META_INSTALL_ID",
"madid": "DEVICE_IDFA_OR_GAID",
"client_ip_address": "203.0.113.10"
},
"app_data": {
"advertiser_tracking_enabled": 1,
"application_tracking_enabled": 1,
"extinfo": ["i2", "", "", "", "17.5", "", "", "", "", "", "", "", "", "", "", ""]
},
"custom_data": {
"currency": "USD",
"value": 9.99
}
}
]
}action_source set to app, advertiser_tracking_enabled (1 if ATT was granted on iOS 14.5 and later, otherwise 0), application_tracking_enabled, and extinfo.a2 for Android or i2 for iOS, and index 4 is the OS version. Use empty strings as placeholders for values you do not have.client_ip_address is not filled automatically. It must be a valid IPv4 or IPv6 address and is not hashed.anon_id and madid are sent as they are.event_id and event_name are deduplicated across the SDK, the App Events API and the Conversions API. Make sure IDs are accurate, or real conversions can be dropped.If your MMP already forwards events to Meta, do not also send them directly. AppsFlyer also notes that ua and ip are required for events sent through its Meta Conversions API endpoint, and are added automatically only for SDK events. Use the Payload Helper and Test Events tools in Events Manager before going live.
Google’s Measurement Protocol guide describes a POST to https://www.google-analytics.com/mp/collect with api_secret and, for an app stream, firebase_app_id as query parameters. Use region1.google-analytics.com for EU data collection. The API secret must stay on your server and never ship inside the app.
POST https://www.google-analytics.com/mp/collect?firebase_app_id=YOUR_FIREBASE_APP_ID&api_secret=YOUR_API_SECRET
{
"app_instance_id": "APP_INSTANCE_ID_FROM_SDK",
"user_id": "user_48213",
"consent": {
"ad_user_data": "GRANTED",
"ad_personalization": "GRANTED"
},
"events": [
{
"name": "subscription_renewed",
"params": {
"currency": "USD",
"value": 9.99
}
}
]
}timestamp_micros is in microseconds, not milliseconds, and can backdate up to 72 hours. In the default relaxed mode an older timestamp is overridden to 72 hours ago, and with ENFORCE_RECOMMENDATIONS it is rejected.session_id, which should come from the Firebase SDK, is needed for several common use cases.consent object takes ad_user_data and ad_personalization. Send GRANTED only when the user granted it. If you omit the object, Google uses consent from the app instance’s earlier interactions.Google also notes that Measurement Protocol will keep working with no planned deprecation, and recommends the Data Manager API for new server-to-server integrations. Check that page when you plan your server-side tracking for mobile apps build.
Server-side tracking for mobile apps does not remove the need for permission. Apple’s ATTrackingManager asks a person for permission to access data that can be used to track them or their device across apps and websites, and you can read the result at any time through trackingAuthorizationStatus.
att on AppsFlyer and advertiser_tracking_enabled on Meta.consent object, and Branch has the dma_eea fields for users in the European Economic Area.Consent rules depend on where your users are, so confirm the legal basis with your own counsel. I am not a lawyer, and this section is a technical checklist only.
You can inspect a payload before it leaves your server with the free mobile app attribution debugger, and the mobile attribution audit guide has a checklist for reviewing a live setup.
id prefix off an iOS app ID for AppsFlyer, so the request returns 200 and nothing is recorded.ip field and Adjust’s ip_address.timestamp_micros.Most failures in server-side tracking for mobile apps come from identifiers and duplicates, not from the API calls themselves. If you are choosing the MMP that will receive these events, see Branch vs AppsFlyer and AppsFlyer vs Adjust.
It is a setup where your own backend sends selected events, such as confirmed purchases and renewals, to a measurement partner, Meta or Google Analytics. The SDK stays in the app for installs, sessions and ad click matching, and the server adds events the phone cannot report cleanly.
Yes. Adjust’s documentation says to use the SDK to record installs, sessions and reattributions, and to send only custom events through S2S. Server-side tracking for mobile apps also depends on identifiers that the SDK captures on the device.
Only in part. Branch states that Apple has no server-side API for reporting conversions, so the app must call Apple itself. Adjust can calculate a conversion value from an S2S event and return it, but the Adjust SDK then applies it on its next request, and Adjust advises using the SDK when timing is tight.
Yes. Meta’s Conversions API for App Events page does not require an MMP. You need an app linked to a dataset, action_source set to app, the tracking flags, the 16-value extinfo array and a client IP address that you add yourself.
It depends on the platform. Adjust rejects events older than 58 days, and GA4 backdates up to 72 hours. AppsFlyer keeps your event time only inside a short window around the event day, and Branch does not backfill past-timestamped events. For server-side tracking for mobile apps, send events promptly.
No. Server-side tracking for mobile apps does not remove the need for the user’s permission. Record the ATT answer, pass consent signals such as the GA4 consent object or Branch’s dma_eea fields, and do not send an advertising ID you do not have.
Choose one source for each event name. Meta deduplicates on event_id together with event_name. The AppsFlyer, Adjust and Branch pages I checked do not describe an equivalent rule, so for those platforms a second source creates a duplicate.
If you want a second pair of eyes on your server-side tracking for mobile apps setup, send a short description to contact@alfahadhridoy.com and I will reply by email with what to check.