Marketing analytics

Last updated:

|Edit this page|

Important: This feature is currently an opt-in beta. You can enable it on the feature previews settings page. Please leave a comment on this page if you have feedback or questions, or leave feedback via the in-app support modal.

Marketing analytics enables you to track marketing campaigns, costs, and performance from multiple advertising platforms in your marketing analytics dashboard.

Marketing dashboard

The marketing dashboard contains multiple pre-built insights helping you understand your campaigns and costs.

Marketing costs over time

Marketing analytics dashboard showing marketing costs over time

The marketing costs chart displays your total advertising spend across all configured data sources:

  • Stacked area visualization shows the contribution of each platform to your total marketing spend
  • Time-based trends help identify spending patterns and budget allocation over the selected date range
  • Date range filtering allows you to analyze costs for specific periods using the date picker
  • Real-time updates reflect new cost data as it syncs from your configured marketing sources (based on your source sync configuration)
  • Currency conversion automatically converts all costs to your configured base currency for consistent reporting

Campaign breakdown

Campaign costs breakdown table showing detailed performance metrics

The campaign breakdown table provides detailed performance metrics by individual campaign:

  • Campaign: Campaign identifier from your advertising platform (should match to utm_campaign value)
  • Source: Ad platform name (e.g., google, should match to utm_source value)
  • Total cost: Total spend for the campaign in your base currency
  • Total clicks: Number of clicks received during the selected period
  • Total impressions: Number of impressions served
  • Cost per click: Average cost per click (total cost ÷ total clicks)
  • CTR: Clickthrough rate percentage (total clicks ÷ total impressions × 100)
  • Conversion goals: Performance against your defined conversion goals
  • Cost per conversion: Cost efficiency for conversions (total cost ÷ conversions)

Settings and configuration

Base currency

Base currency configuration

PostHog converts currency values for the entire team to the base currency you set in your project settings before displaying them. If we can't properly detect your currency from the source data, we'll assume it's in this currency as well.

Conversion goals

Conversion goals configuration

Define conversion goals by selecting events, actions, or data warehouse tables. These goals are used to track and analyze user conversions in your marketing analytics.

To configure conversion goals, select:

  • Conversion goal name: Descriptive name (e.g., purchase, sign up, download)
  • Event, action or data warehouse table: Select what to track for conversions
  • Schema mapping: For data warehouse tables, map campaign and source attribution fields. For events, PostHog uses UTM parameters: utm_campaign and utm_source

Native data warehouse sources

Native data warehouse sources configuration

PostHog can automatically sync marketing data from support platforms like Google Ads by configuring them as native sources. You'll need to sync the required tables for each source to enable the functionality.

The simplest way to add marketing data is to add a Google Ads source by following this guide.

Required tables for native sources:

  • campaign: Contains campaign information and metadata
  • campaign_stats: Maps campaigns with performance statistics for each time period

Non-native data warehouse sources

Non-native data warehouse sources configuration

Alternatively, you can use an external data warehouse sources to display marketing analytics. You'll need to map the required columns for each table to enable the functionality. Currently, only BigQuery tables are supported.

Configuring data warehouse source mapping with required and optional fields

Required field mappings:

  • Campaign: Campaign identifier or name (mapped to utm_campaign query param)
  • Cost: Cost amount for the period
  • Date: Date of the data record
  • Source: Platform name (mapped to utm_source query param)

Optional field mappings:

  • Clicks: Number of clicks received
  • Currency: Currency code for cost values
  • Impressions: Number of impressions served

Self-managed data warehouse sources

Self-managed data warehouse sources configuration

Another option to get marketing analytics data is to configure and use self-managed sources from S3, GCS, Cloudflare R2, and Azure. You'll need to map the required columns for each table to enable the functionality.

Note: We strongly recommend using JSON format for better support and troubleshooting. Like data warehouse tables, you simply need to create a connection between PostHog and your marketing source, map the desired fields, and PostHog will automatically sync the marketing data.

Please refer to the data pipeline docs for more information on configuring external data sources.

Questions? Ask Max AI.

It's easier than reading through 680 pages of documentation

Community questions

Was this page useful?

Next article

FAQs

Have a question not covered here? Let us know . What is the difference between web analytics and product analytics? Web analytics is a streamlined experience for tracking and monitoring your most important website metrics. Product analytics is a more powerful and flexible experience for tracking your product. For a more detailed description of the difference, check out our page on web vs product analytics . How much does web analytics cost? Web analytics is no additional cost on top of product…

Read next article