The Google Analytics Data API v1 produces reports for [Google Analytics
properties](https://support.google.com/analytics/answer/9304153#property).
API requests are required to specify a numeric Google Analytics property
identifier. The documentation and sample code of the Data API refer to
this ID as `GA_PROPERTY_ID`.

## Usage

All Data API methods require the Google Analytics property identifier to be
specified inside a URL request path in the form of `properties/GA_PROPERTY_ID`,
such as:

      POST https://analyticsdata.googleapis.com/v1beta/properties/GA_PROPERTY_ID:runReport

If you are using one of the [Data API client libraries](https://developers.google.com/analytics/devguides/reporting/data/v1/client-libraries), there
is no need to manipulate the request URL path manually. Most API clients
provide a `property` parameter that expects a string in the form of
`properties/GA_PROPERTY_ID`. See [Quick start guide](https://developers.google.com/analytics/devguides/reporting/data/v1/quickstart)
for examples of using the client libraries.

## What is my property ID?

You can use the Data API if you have configured analytics reports in either of
the following products:

### Google Analytics

To determine a Google Analytics property ID:

1. Visit Google Analytics at <https://analytics.google.com/>.
2. Select Admin.
3. Select the Property.
4. Select Property Settings.

If the Property Settings shows a numeric "PROPERTY ID" such as "123...", this
is the numeric ID of your Google Analytics property.

### Firebase

If you have linked Google Analytics to Firebase, you will see analytics data for
your project in Firebase. To learn more about linking, see
[Link Google Analytics to Firebase](https://support.google.com/analytics/answer/9289234).

To determine the Google Analytics property for a Firebase project:

1. Visit the Firebase console at <https://console.firebase.google.com/>.
2. Select your project.
3. Select Project settings.
4. Select Integrations.
5. Select your Google Analytics Integration.

The Google Analytics Integration page will show a numeric "Property ID" such as
"123...". This is the numeric ID of your Google Analytics property.

### AdMob

If you use AdMob, your app must be linked to Firebase to use Google Analytics.
To access user metrics within AdMob and use the Google Analytics Data API,
you must have:

1. [Linked your AdMob app to a Firebase
   project](https://support.google.com/admob/answer/6383165).
2. Integrated the Google Analytics for Firebase SDK into your app.
3. [Enabled user metrics](https://support.google.com/admob/answer/9263723) for your app in AdMob.

These steps are required to collect [user metrics for AdMob](https://support.google.com/admob/answer/9281746) and to
[explore and work with this data](https://firebase.google.com/docs/admob/analytics-and-firebase) using Google Analytics and the Data API.

To find the Google Analytics Property ID associated with your AdMob app:

1. Sign in to [AdMob](https://apps.admob.com/).
2. Select your app from the app list.
3. In the sidebar, select **App settings**.
4. In the **Firebase** section, you should see details about the linked Firebase project. Click the appropriate link or button to navigate to the Firebase console.
   - *Alternative path:* Sometimes, a link to the Firebase dashboard might be available on the **App overview** page.
5. In the Firebase console, you are viewing the project linked to your AdMob app. Follow the instructions outlined in the [Firebase section](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id#firebase) to find the Property ID:
   - Select **Project settings** (gear icon next to Project Overview).
   - Go to the **Integrations** tab.
   - Select the **Google Analytics** integration to view the **Property ID**.