Linking Amazon Ads as a source
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.

The Amazon Ads connector pulls your Amazon advertising data into the PostHog data warehouse. This includes entities for Sponsored Products, Sponsored Brands, Sponsored Display, and Sponsored TV, daily performance reports, budget rules, invoices, and change history.
You need a Login with Amazon (LWA) application with Advertising API access. PostHog uses your LWA credentials to authenticate with Amazon's Advertising API and sync data from every advertising profile your token can access.
Adding a data source
- Go to the sources tab of the data pipeline section in PostHog.
- Click + New source and then click Link next to Amazon Ads.
- Select the Region that matches your Amazon advertising profiles:
- North America – US, Canada, Mexico, Brazil
- Europe – UK, Germany, France, Italy, Spain, and others
- Far East – Japan, Australia, Singapore
- Enter your Login with Amazon credentials:
- LWA client ID – Your application's client ID (starts with
amzn1.application-oa2-client...) - LWA client secret – Your application's client secret
- Refresh token – An authorized refresh token from your LWA app (starts with
Atzr|...)
- LWA client ID – Your application's client ID (starts with
- Click Next.
- Select the tables you want to sync, set the sync method and frequency, then click Import.
To obtain these credentials, create a Login with Amazon application in the Amazon Developer Console and request access to the Amazon Advertising API.
PostHog validates your credentials at connect time by minting an access token and listing your advertising profiles. If the token doesn't have Advertising API access, the connection fails immediately.
Once the syncs are complete, you can start using Amazon Ads data in PostHog.
Sync methods
The sync method depends on the type of table:
- Report tables (tables that end in
_reports, such assp_campaign_reports) support incremental sync on thedatefield. Each sync reloads a lookback window, because Amazon can update recent report data after it first appears. - Change history (
change_history) supports incremental sync on thetimestampfield. Each sync reloads the last 24 hours, because Amazon can record an event after a sync has run. - Entity tables (all other tables, such as
profiles,sp_campaigns, andsp_ad_groups) use full refresh sync, because the Amazon Ads API doesn't expose an updated-since filter for entity lists. Each sync reloads all data.
Rows from profile-level tables include a _profile_id field that identifies the advertising profile they belong to. Data is synced from every profile your token can access.
Configuration
| Option | Type | Required |
|---|---|---|
Region | select | Yes |
LWA client ID | text | Yes |
LWA client secret | password | Yes |
Refresh token | password | Yes |
Supported tables
| Table | Description | Sync method | Incremental field | Primary key |
|---|---|---|---|---|
profiles | An advertising profile representing an account in a specific marketplace/region. | Full refresh | — | — |
sp_campaigns | A Sponsored Products campaign that groups ad groups under a budget and targeting strategy. | Full refresh | — | — |
sp_ad_groups | A Sponsored Products ad group within a campaign, grouping ads and keywords under a default bid. | Full refresh | — | — |
sp_product_ads | A Sponsored Products ad: one advertised product (ASIN or SKU) inside an ad group. | Full refresh | — | — |
sp_keywords | A Sponsored Products keyword target, with the bid and match type used to buy that search. | Full refresh | — | — |
sp_targets | A Sponsored Products targeting clause: a product or category targeting expression with its bid. | Full refresh | — | — |
sp_negative_keywords | A Sponsored Products negative keyword on an ad group, excluding a shopper search from that ad group. | Full refresh | — | — |
sp_campaign_negative_keywords | A Sponsored Products negative keyword on a campaign, excluding a shopper search from every ad group in it. | Full refresh | — | — |
sp_negative_targets | A Sponsored Products negative product or category target on an ad group, excluding those products from that ad group. | Full refresh | — | — |
sp_campaign_negative_targets | A Sponsored Products negative product or category target on a campaign, excluding those products from every ad group in it. | Full refresh | — | — |
portfolios | A portfolio: a group of campaigns that shares a budget, which resolves the portfolioId the campaign tables carry. | Full refresh | — | — |
sb_campaigns | A Sponsored Brands campaign that groups ad groups under a budget and a targeting strategy. | Full refresh | — | — |
sb_ad_groups | A Sponsored Brands ad group within a campaign, grouping its ads and targets. | Full refresh | — | — |
sb_ads | A Sponsored Brands ad: one creative inside an ad group. | Full refresh | — | — |
sb_targets | A Sponsored Brands target: one targeting expression with its bid, positive or negative. | Full refresh | — | — |
sd_campaigns | A Sponsored Display campaign that groups ad groups under a budget and a targeting strategy. | Full refresh | — | — |
sd_ad_groups | A Sponsored Display ad group within a campaign, grouping its ads and targets. | Full refresh | — | — |
sd_ads | A Sponsored Display ad: one creative inside an ad group. | Full refresh | — | — |
sd_targets | A Sponsored Display target: one targeting expression with its bid, positive or negative. | Full refresh | — | — |
ads_accounts | A global advertising account, which groups the regional profiles of one advertiser. | Full refresh | — | — |
invoices | An advertising invoice summary for a profile: billed amounts, taxes, and payment status. | Full refresh | — | — |
change_history | A change to a Sponsored Products or Sponsored Brands entity, such as a status, bid, or budget change, from the last 90 days. | Incremental, Full refresh | timestamp | — |
sp_campaign_reports | Daily Sponsored Products performance for each campaign, from the async reporting API. | Incremental, Full refresh | date | — |
sp_search_term_reports | Daily Sponsored Products performance for each customer search term that led to at least one ad click, by the keyword or targeting clause that matched it. | Incremental, Full refresh | date | — |
sp_advertised_product_reports | Daily Sponsored Products performance for each advertised product (ad). | Incremental, Full refresh | date | — |
sp_targeting_reports | Daily Sponsored Products performance for each keyword and targeting expression. | Incremental, Full refresh | date | — |
sp_purchased_product_reports | Daily Sponsored Products sales of products other than the advertised one, attributed to the ad clicked. | Incremental, Full refresh | date | — |
sb_purchased_product_reports | Daily Sponsored Brands sales for each purchased product, attributed to the campaign. | Incremental, Full refresh | date | — |
sp_budget_rules | A Sponsored Products budget rule that raises campaign budgets on a schedule or when a performance condition is met. | Full refresh | — | — |
sp_budget_rule_campaigns | A Sponsored Products campaign that a budget rule applies to. | Full refresh | — | — |
st_campaigns | A Sponsored TV campaign. | Full refresh | — | — |
st_ad_groups | A Sponsored TV ad group within a campaign. | Full refresh | — | — |
st_ads | A Sponsored TV ad within an ad group. | Full refresh | — | — |
st_targets | A Sponsored TV targeting clause within an ad group. | Full refresh | — | — |





