# How to retrieve refresh token using React Native SDK

**URL:** <https://community.auth0.com/t/how-to-retrieve-refresh-token-using-react-native-sdk/63734>\
**Category:** Get Help\
**Tags:** jwt, auth0\
**Created:** [June 2, 2021, 2:22pm UTC](https://community.auth0.com/t/how-to-retrieve-refresh-token-using-react-native-sdk/63734 "2021-06-02T14:22:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![marbaez](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/marbaez/32/29289_2.png) [@marbaez](https://community.auth0.com/u/marbaez)\
**Post date:** [June 2, 2021, 2:22pm UTC](https://community.auth0.com/t/how-to-retrieve-refresh-token-using-react-native-sdk/63734/1 "2021-06-02T14:22:17Z")

</div>

Please include the following information in your post:

- **Which SDK this is regarding:** e.g. react-native-auth0
- **Platform Version:** React Native

Using the React Native SDK, how can we retrieve the `refresh_token` for a user that has just logged in using the `auth.authorize` action?

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [June 2, 2021, 9:56pm UTC](https://community.auth0.com/t/how-to-retrieve-refresh-token-using-react-native-sdk/63734/3 "2021-06-02T21:56:47Z")

</div>

Hi @marbaez,

To get refresh tokens, you must include the `offline_access` scope.

It _appears_ to be supported by that SDK. Can you try adding it to your existing scopes and see if the response includes a refresh token?

For example:

```auto
auth0.webAuth
  .authorize({scope: 'openid email profile offline_access})
  .then(credentials => console.log(credentials))
  .catch(error => console.log(error));

```

This doc explains what is happening when you pass this scope:

> **[Get Refresh Tokens](https://auth0.com/docs/secure/tokens/refresh-tokens/get-refresh-tokens)**
>
> Describes how to get a Refresh Token when you initiate a request using the Authorize endpoint.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [July 13, 2021, 4:31pm UTC](https://community.auth0.com/t/how-to-retrieve-refresh-token-using-react-native-sdk/63734/4 "2021-07-13T16:31:44Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
