Overview
Cohort Analytics is a powerful tool that helps you not only understand the full ROI of your campaigns, but also helps you guide future investment decisions and consumer targeting.
With the Branch Cohort API, you can access Cohort Analytics data programmatically.
Benefits of Cohort API
Cohorts Analytics data allows you to analyze your cross-channel, cross-platform performance by either acquisition date (app install only) or re-engagement date (web and app sessions), to see how those users performed over time.
Limitations
Limitation | Details |
|---|---|
Max Number of Records Returned | 50,000 |
Export Window | Rolling 2 year window. |
Max Number of Dimensions | 11 dimensions. |
Max Number of Measures | 5 measures. |
Max Number of Days Queried | 90 days. |
Rate Limits | 2 requests per second. |
Getting Started
Before you begin
In order to use the Cohort API, you first need to:
Create a Branch Dashboard.
Implement the appropriate Branch SDK into your mobile app (iOS | Android).
Make sure you have the appropriate permissions set on your user account. See the "Access" section for more.
Access
General Access
To access the Async Aggregate API, a user must have both Aggregate Data and Export access enabled on their account.
Agency Access
If you work with an agency that runs your advertising campaigns and want to give them access to export the subsequent data, you can provide them with access to the Cohort API.
To provide an agency team member with access to the Cohort API:
In the left-hand navigation, under Setup & Testing, click on Account Settings.
On the Account Settings page, click on the Agencies tab.
Expand the agency in question, find the agency team member you want to give access to, hover on the button in the Actions column, and click Edit.
In the Edit Agency Team Member modal:
Under Access Level, check the Export box.
Under Permissions, check the Aggregate Data box.
Optional: add data filters
Under Data Filters, toggle any necessary data filters on/blue. Exported data will be filtered accordingly.
Click Save.
.png?sv=2026-02-06&spr=https&st=2026-09-20T02%3A42%3A13Z&se=2026-09-20T03%3A03%3A13Z&sr=c&sp=r&sig=WXth5VUiPznV8zr3HZuw02K2PbtI85oI8oDkr3I%2FJro%3D)
Agency-Tagged Data
If you do not enable the Only Show Agency-Tagged Data data filter, the Agency Team Member will be able to export aggregate data associated with all of your campaigns, regardless if they are associated with them or not.
Authentication
For calls to the Cohort API, you will need your Access Token.
To retrieve your credentials in the legacy Branch experience:
Navigate to the Account → Settings → User tab.
If you have not yet generated an Access Token, select the Generate token button.
Use the copy icon to copy your Access Token.
To retrieve your credentials in the new Branch experience:
Navigate to the Configuration → Security & Access → Credentials tab.
If you have not yet generated an Access Token, select the Generate token button.
Use the copy icon to copy your Access Token.
Visit our guide to learn more about managing your Branch credentials.
Usage
Export Cohort Analytics
Request Info
Export Request
POST https://api2.branch.io/v2/analytics
Content-Type: application/json
Host: api2.branch.ioRequest Headers
Header | Description | Required |
|---|---|---|
| Key that encapsulates the user's permission with regards to an organization. Obtained from the Branch Dashboard. Needed for authentication. | Yes |
| application/json | Recommended |
| application/json | Recommended |
Request Query Parameters
Parameter | Description | Required |
|---|---|---|
| Unique identifier for the organization of requested data. | Yes |
| The maximum number of results to return. | No |
| Format of the returned data. Defaults to CSV. | No |
Request Body Parameters
Parameter | Type | Description | Required |
|---|---|---|---|
| Date | The start of the interval time range represented as an ISO-8601 complete date. | Yes |
| Date | The end of the interval time range represented as an ISO-8601 complete date. | Yes |
| Array of Strings | An array representing dimension(s) to group by. See the "Dimensions" section for a complete list. | No |
| String | A string value representing the cohort type. Can be either: | Yes |
| Array of Strings | Keys are same as dimensions. Values are an array of values to match for the dimension. | No |
| String | Order of response, based on | No |
| String | The dimension name used for sorting. | No |
| String | The cohort measures names to return. | Yes |
| Integer | Number of time units since the cohort event to return to the user. | Yes |
| Boolean | If | No |
| Boolean | If | No |
| String | The time granularity that each band value will represent. | No |
| Boolean | If | No |
Response Info
Response Body Parameters
Parameter | Description |
|---|---|
|