# Linking AppsFlyer as a source - Docs

![](https://res.cloudinary.com/dmukukwp6/image/upload/texture_tan_9608fcca70)

![](https://res.cloudinary.com/dmukukwp6/image/upload/texture_tan_dark_a92b0e022d)

Let AI connect your sources for you

Skip the manual setup — run this in your project and the wizard auto-detects your databases and APIs and connects them to PostHog.

`npx @posthog/wizard warehouse`

[Learn more](/wizard.md)

![PostHog Wizard hedgehog](https://res.cloudinary.com/dmukukwp6/image/upload/wizard_3f8bb7a240.png)

**Alpha release**

This source is currently in **alpha**. The interface and available tables may change.

Enter your AppsFlyer credentials to pull aggregate mobile attribution reports into the PostHog data warehouse. Each source connects to a single AppsFlyer app.

## Adding a data source

1.  Go to the [sources tab](https://app.posthog.com/data-management/sources) of the data pipeline section in PostHog.
2.  Click **\+ New source** and then click **Link** next to AppsFlyer.
3.  In AppsFlyer, go to your **account menu** > **Security center** > **AppsFlyer API tokens** and copy your **API token (V2)**. Your account must have an active Pull API subscription.
4.  Find your **App ID** in the AppsFlyer dashboard — for example, `id123456789` for iOS or the Android package name.
5.  Back in PostHog, enter the **App ID** and **API token (V2)**, then click **Next**.
6.  Select the tables you want to sync, set the sync method and frequency, then click **Import**.

Once the syncs are complete, you can start using AppsFlyer data in PostHog.

## Available tables

| Table | Description | Sync method |
| --- | --- | --- |
| daily_report | Daily aggregate performance data | Incremental |
| geo_report | Geographic breakdown of performance data | Incremental |
| partners_report | Partner attribution data | Incremental |

All tables sync incrementally on the `date` field.

## Sync behavior

-   **Incremental sync with lookback** - AppsFlyer doesn't finalize data until approximately 48 hours after the UTC day. Each incremental sync re-fetches the trailing two days to capture late-arriving data. Duplicates are merged on the dimension key.
-   **Initial sync** - The first sync can pull up to approximately 1,000 days of historical data, the maximum window supported by the AppsFlyer aggregate Pull API.
-   **One app per source** - Each source connects to a single AppsFlyer app. To import data from multiple apps, create a separate source for each one.

## Configuration

| Option | Type | Required |
| --- | --- | --- |
| App ID | text | Yes |
| API token (V2) | password | Yes |

## Supported tables

| Table | Description | Sync method | Incremental field | Primary key |
| --- | --- | --- | --- | --- |
| daily_report | Daily aggregate performance per media source and campaign — installs, clicks, cost, and revenue by date. | Incremental, Full refresh | date | — |
| geo_report | Daily aggregate performance broken down by country, in addition to media source and campaign. | Incremental, Full refresh | date | — |
| partners_report | Daily aggregate performance broken down by attribution partner (media source). | Incremental, Full refresh | date | — |

### Community questions

Ask a question

### Was this page useful?

HelpfulCould be better