> ## Documentation Index
> Fetch the complete documentation index at: https://auth0.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Refresh Token Metadata

> Learn how Auth0 refresh token metadata can help you store custom data on a refresh token that persists across uses and is accessible from Actions and the Management API.

Refresh token metadata allows the storage of customizable keys and values (maximum 255 characters each) in an Auth0 [refresh token](https://auth0.com/docs/secure/tokens/refresh-tokens).

Use cases for refresh token metadata include:

* Track device information, such as device name or login location
* Store token-level flags, for example, `user_accepted_terms` or `session_type`
* Share state between multiple Actions in the same flow
* Drive conditional logic for token issuance or revocation
* Audit and analytics pipelines that need to be aware of user context data

You can access and modify refresh token metadata during a refresh token's lifecycle using Auth0 [Actions](https://auth0.com/docs/customize/actions/explore-triggers/post-login.md) and the [Management API](https://auth0.com/docs/api/management/v2.md).

To learn more, read [how to Configure Refresh Token Metadata](https://auth0.com/docs/secure/tokens/refresh-tokens/refresh-token-metadata/configure-refresh-token-metadata.md).

> [!WARNING]
>
> Refresh token metadata is not a secure data store. Do not use it to store sensitive information, like secrets, credit card numbers, social security numbers, or other high-risk PII.
>
> To learn more, read [Auth0 General Data Protection Regulation Compliance](https://auth0.com/docs/secure/data-privacy-and-compliance/gdpr).

## Supported flows

You can set refresh token metadata using Post-Login Actions with the following OAuth 2.0 flows:

* Authorization Code Flow
* Resource Owner Password Grant
* Device Authorization Grant
* Federated Connection Flows
* Client-Initiated Backchannel Authentication (CIBA)
* Native Passkeys
* Refresh Token Exchange

You can **set** refresh token metadata during any of the supported flows above. However, existing metadata is only **available to read** via the `event.refresh_token.metadata` object during [refresh token exchange](https://auth0.com/docs/secure/tokens/refresh-tokens/use-refresh-tokens.md) scenarios where `event.refresh_token` exists. At the initial login, `event.refresh_token` does not exist, so you can only set metadata—not read it. During a refresh token exchange, you can both read existing metadata and set new values.

When executing a refresh token exchange, the metadata set in Actions is applied when the refresh token is issued, not during intermediate steps such as MFA challenges.

## Limitations

* Refresh token metadata is limited to 25 entries maximum
* Each key and value must be 255 characters or less
* Metadata keys may only include letters, numbers, underscores, or hyphens

## Learn more

* [Configure Refresh Token Metadata](https://auth0.com/docs/secure/tokens/refresh-tokens/refresh-token-metadata/configure-refresh-token-metadata.md)
* [Refresh Tokens with Actions](https://auth0.com/docs/secure/tokens/refresh-tokens/manage-refresh-tokens-actions.md)
* [Refresh Tokens](https://auth0.com/docs/secure/tokens/refresh-tokens)
