Take our developer survey. We want your feedback so we can learn how to improve Google Analytics, and make it an even better tool for you.

Realtime Dimensions & Metrics

The dimensions and metrics supported in queries to the Realtime method of the Analytics Data API. The Core Reporting methods (RunReport for example) accept a different set of Dimensions & Metrics than the Realtime method.

Dimensions

The following dimensions can be requested in reports for any property. Specify the "API Name" in a Dimension's name field for a column of the dimension in the report response.

API Name UI Name Description
appVersion App version The app's versionName (Android) or short bundle version (iOS).
audienceId Audience ID The numeric identifier of an Audience. Users are reported in the audiences to which they belonged during the report's date range. Current user behavior does not affect historical audience membership in reports.
audienceName Audience name The given name of an Audience. Users are reported in the audiences to which they belonged during the report's date range. Current user behavior does not affect historical audience membership in reports.
city City The city from which the user activity originated.
cityId City ID The geographic ID of the city from which the user activity originated, derived from their IP address.
country Country The country from which the user activity originated.
countryId Country ID The geographic ID of the country from which the user activity originated, derived from their IP address. Formatted according to ISO 3166-1 alpha-2 standard.
deviceCategory Device category The type of device: Desktop, Tablet, or Mobile.
eventName Event name The name of the event.
platform Platform The platform on which your app or website ran; for example, web, iOS, or Android. To determine a stream's type in a report, use both platform and streamId.
streamId Stream ID The numeric data stream identifier for your app or website.
streamName Stream name The data stream name for your app or website.
unifiedScreenName Page title and screen name The page title (web) or screen name (app) on which the event was logged.

Custom Dimensions

The Realtime Data API can create reports on User scoped Custom Dimensions. See Custom user properties to learn more about custom dimensions. Custom dimensions are specified in an API report request by the dimension's parameter name and scope. For example, include "customUser:last_level" in a Data API request to create a report for the User-scoped Custom Dimension with parameter name "last_level". This API request will fail if the property has not registered this User-scoped Custom Dimension.

The following are the general syntax for Custom Dimensions. You can query the Metadata API method to list all Custom Dimensions for a Property.

Generic API Name Description
customUser:parameter_name User-scoped Custom Dimension for parameter_name

Event-scoped custom dimensions are not currently supported in the Realtime API.

Metrics

The following metrics can be requested in reports for any property. Specify the "API Name" in a Metric's name field for a column of the metric in the report response.

API Name UI Name Description
activeUsers Active users The number of distinct users who visited your site or app.
conversions Conversions The count of conversion events. Events are marked as conversions at collection time; changes to an event's conversion marking apply going forward. You can mark any event as a conversion in Google Analytics, and some events (i.e. first_open, purchase) are marked as conversions by default. To learn more, see https://support.google.com/analytics/answer/9267568.
eventCount Event count The count of events.
screenPageViews Views The number of app screens or web pages your users viewed. Repeated views of a single page or screen are counted. (screen_view + page_view events).

Event-scoped custom metrics are not currently supported in the Realtime API.