---
title: "GET /v1beta/properties/{propertiesId}/dataRetentionSettings"
method: GET
path: "/v1beta/properties/{propertiesId}/dataRetentionSettings"
tags: ["properties"]
---

# GET /v1beta/properties/{propertiesId}/dataRetentionSettings

`GET /v1beta/properties/{propertiesId}/dataRetentionSettings`

## Request

- Base URL: `https://analyticsadmin.googleapis.com`
- URL: `https://analyticsadmin.googleapis.com/v1beta/properties/{propertiesId}/dataRetentionSettings`
- Auth: one of:
  - OAuth 2 and OAuth 2
    - Implicit: `https://accounts.google.com/o/oauth2/auth`
    - Scopes: `https://www.googleapis.com/auth/analytics.edit`
    - Authorization code: `https://accounts.google.com/o/oauth2/auth`
    - Token URL: `https://accounts.google.com/o/oauth2/token` scopes: `https://www.googleapis.com/auth/analytics.edit`
  - OAuth 2 and OAuth 2
    - Implicit: `https://accounts.google.com/o/oauth2/auth`
    - Scopes: `https://www.googleapis.com/auth/analytics.readonly`
    - Authorization code: `https://accounts.google.com/o/oauth2/auth`
    - Token URL: `https://accounts.google.com/o/oauth2/token` scopes: `https://www.googleapis.com/auth/analytics.readonly`

Returns the singleton data retention settings for this property.

## Path parameters

- `propertiesId` string, required

## Query parameters

- `$.xgafv` '1' | '2'
- `access_token` string
- `alt` 'json' | 'media' | 'proto'
- `callback` string
- `fields` string
- `key` string
- `oauth_token` string
- `prettyPrint` boolean
- `quotaUser` string
- `uploadType` string
- `upload_protocol` string

## Response `200`

Successful response

- GoogleAnalyticsAdminV1betaDataRetentionSettings: Settings values for data retention. This is a singleton resource.
  - `eventDataRetention` 'RETENTION_DURATION_UNSPECIFIED' | 'TWO_MONTHS' | 'FOURTEEN_MONTHS' | 'TWENTY_SIX_MONTHS' | 'THIRTY_EIGHT_MONTHS' | 'FIFTY_MONTHS': Required. The length of time that event-level data is retained.
  - `name` string: Identifier. Resource name for this DataRetentionSetting resource. Format: properties/{property}/dataRetentionSettings
  - `resetUserDataOnNewActivity` boolean: If true, reset the retention period for the user identifier with every event from that user.
  - `userDataRetention` 'RETENTION_DURATION_UNSPECIFIED' | 'TWO_MONTHS' | 'FOURTEEN_MONTHS' | 'TWENTY_SIX_MONTHS' | 'THIRTY_EIGHT_MONTHS' | 'FIFTY_MONTHS': Required. The length of time that user-level data is retained.

## Changes

- **2026-10-29** `2f06698abda1`: 4 info
  - the security scope `https://www.googleapis.com/auth/analytics.edit` was added to the endpoint's security scheme `Oauth2`
  - the security scope `https://www.googleapis.com/auth/analytics.edit` was added to the endpoint's security scheme `Oauth2c`
  - the security scope `https://www.googleapis.com/auth/analytics.readonly` was removed from the endpoint's security scheme `Oauth2`
  - the security scope `https://www.googleapis.com/auth/analytics.readonly` was removed from the endpoint's security scheme `Oauth2c`

[Operation history](https://skmtc.dev/google/apis/analyticsadmin/changes/v1beta/properties/:propertiesId/dataRetentionSettings/get.md)

---

[API](https://skmtc.dev/google/apis/analyticsadmin.md) - [All operations](https://skmtc.dev/google/apis/analyticsadmin/llms.txt) - [OpenAPI document](https://skmtc.dev/google/apis/analyticsadmin/revisions/2f06698abda1?raw)
