# Google Analytics 4 connector

> How to connect GA4 to Windsor.ai, available fields, query limits, and known API limitations.

The Google Analytics 4 connector pulls session, event, e-commerce, and audience data from GA4 properties via the Google Analytics Data API. It exposes 482 fields: 92 metrics and 390 dimensions.

## Connecting Google Analytics 4

**Option A: OAuth (personal or service account via Google login)**

1. Go to [onboard.windsor.ai](https://onboard.windsor.ai/) and find the **Google Analytics 4** connector.
2. Click **Connect** and sign in with the Google account that has at least Viewer access to your GA4 property.
3. Grant Windsor read permissions.
4. Select the GA4 property you want to query.

**Option B: Service account**

Using a Google Cloud service account is recommended for agency or multi-property setups, as it avoids token expiry tied to a personal login. See [How to connect GA4 to Windsor.ai using a service account](https://windsor.ai/documentation/troubleshooting/how-to-connect-ga4-to-windsor-ai-using-a-service-account.md) for step-by-step instructions.

## Available fields

**Metrics (92):**

- Sessions, users, new users, returning users
- Engaged sessions, engagement rate, bounce rate
- Average session duration, session duration
- Events, conversions, conversion rate
- Purchase revenue, transactions, average order value, ARPU
- Items purchased, item revenue, cart-to-view rate

**Dimension categories (390):**

- **Traffic source**: source, medium, campaign, channel group, landing page
- **Attribution**: Google Ads campaign, DV360, CM360
- **Geography**: country, region, city, continent
- **Device**: browser, OS, device category, screen resolution
- **Page/Screen**: page path, page title, screen class, referrer
- **E-commerce**: item name, item category, brand, item list
- **Demographics**: age, gender (where available)
- **Date**: date, week, month, year, day of week

## Query limits

The GA4 Data API enforces strict limits per query:

- **Maximum 10 metrics** per request
- **Maximum 9 dimensions** per request

If you need more fields, split them across multiple Windsor queries. See [GA4 request errors: dimension and metric limits](https://windsor.ai/documentation/troubleshooting/ga4-request-limits-date-presets-and-filters.md).

## Known limitations

**Incompatible dimension/metric combinations**: Not all metrics and dimensions can be queried together. GA4 returns a "fields cannot be queried together" error when you request an invalid combination. See [GA4 "Some of the Selected Fields Cannot Be Queried Together" error](https://windsor.ai/documentation/troubleshooting/ga4-fields-cannot-be-queried-together-error.md).

**Unexpected field names**: Windsor field IDs for GA4 do not always match the names displayed in the GA4 UI. For example, `sessionSource` in Windsor maps to "Session source" in GA4. See [GA4 "Unexpected Field(s)" error](https://windsor.ai/documentation/troubleshooting/ga4-unexpected-field-error.md).

**Data sampling**: GA4 applies sampling to free properties when queries cover large date ranges. BigQuery export (via Google's native GA4 BigQuery link) provides unsampled data.

**Data discrepancies**: GA4 uses a different session and attribution model than Universal Analytics. See [Data discrepancies in Google Analytics 4](https://windsor.ai/documentation/troubleshooting/data-discrepancies-in-google-analytics-4.md).

## Troubleshooting

- [GA4 "Unexpected Field(s)" error](https://windsor.ai/documentation/troubleshooting/ga4-unexpected-field-error.md)
- [GA4 "Fields Cannot Be Queried Together" error](https://windsor.ai/documentation/troubleshooting/ga4-fields-cannot-be-queried-together-error.md)
- [GA4 request errors: limits, date presets and filters](https://windsor.ai/documentation/troubleshooting/ga4-request-limits-date-presets-and-filters.md)
- [Data discrepancies in Google Analytics 4](https://windsor.ai/documentation/troubleshooting/data-discrepancies-in-google-analytics-4.md)
- [How to connect GA4 using a service account](https://windsor.ai/documentation/troubleshooting/how-to-connect-ga4-to-windsor-ai-using-a-service-account.md)
