# Auth0 doesn't work on React Native

**URL:** <https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454>\
**Category:** Get Help\
**Tags:** login-prompt-new-experience, login-experience\
**Created:** [July 3, 2023, 10:21am UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454 "2023-07-03T10:21:51Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![anna.s.logacheva](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/anna.s.logacheva/32/45089_2.png) [@anna.s.logacheva](https://community.auth0.com/u/anna.s.logacheva)\
**Post date:** [July 3, 2023, 10:21am UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/1 "2023-07-03T10:21:51Z")

</div>

Hello. I want to integrate Auth0 to react native application. I installed react-native-auth0 and passed all steps from quickstart guide [https://manage.auth0.com/dashboard/eu/sleepschool/applications/ylbvtOC54yfXdFcwA9EVMhUZHum468SO/quickstart](https://manage.auth0.com/dashboard/eu/sleepschool/applications/ylbvtOC54yfXdFcwA9EVMhUZHum468SO/quickstart)  
But it doesn’t work.  
On android neigther login with google and logout doesn’t work. Sometimes I see auth0 page, but when I click on sign in with google button it closes and I redirected back to the app. User object is equal null always. But most of time I do not even see auth0 page, I see error in console error:', { [TypeError: Network request failed] line: 103, column: 8201, sourceURL: ‘index.android.bundle’ }

On IOS, most of time I see error [Safari cannot open the page because the address is invalid](https://community.auth0.com/t/swift-auth0-safari-cannot-open-the-page-because-the-address-is-invalid/12053)  
But sometimes I see auth0 page and can login with google and get user object. But after that, I can’t logout. I see the same safari error.

“react”: “18.1.0”,  
“react-native”: “0.70.3”,  
“react-native-auth0”: “^2.17.4”,

I tested from android device and it works, both login with google and logout. But it doesn’t work on simulators  
Can I fix that somehow?  
I do not have IOS device, so I can’t know if that work on IOS device at all.

---

<div class="post-metadata">

**Author:** ![marcelina.barycka](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/marcelina.barycka/32/56162_2.png) [@marcelina.barycka](https://community.auth0.com/u/marcelina.barycka)\
**Post date:** [July 4, 2023, 10:02am UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/3 "2023-07-04T10:02:20Z")

</div>

Hey there Anna, welcome to Auth0!

First of all, it’s great to hear you successfully tested the SDK with your Android device!

Can you please let me know which quickstart did you follow (the link you’ve sent to us doesn’t bring me to any specific quickstart, unfortunately):

1. Is this a [beta quick start](https://auth0.com/docs/quickstart/native/react-native/interactive) or [this one](https://auth0.com/docs/quickstart/native/react-native/00-login)?

Also, let’s try to separate issues with simulators, react native SDK and the react-native-auth0 SDK itself.

To address the bundle issues, can you please try these:  
In your app root:

1. `npm start --reset-cache`

and / or:

1. `yarn run ios` or `yarn run android`

Please let me know if that helped or reach out with result! Thanks!  
At the bottom of this [page](https://github.com/auth0/react-native-auth0), there are a couple of useful links on where and how to report issues with react-native-auth0 SDK directly to its owners.

---

<div class="post-metadata">

**Author:** ![anna.s.logacheva](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/anna.s.logacheva/32/45089_2.png) [@anna.s.logacheva](https://community.auth0.com/u/anna.s.logacheva)\
**Post date:** [July 17, 2023, 10:18am UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/4 "2023-07-17T10:18:55Z")

</div>

Hello. Thanks for your answer.  
I’ve tried your solutions, it doesn’t help.  
And I tested from IOS device and login with google works, but sign out doesn’t. I think it works somehow, because until I do signout, it prevents me to signin again.  
But after I do signout I see safary error page.  
Regards, Anna.

---

<div class="post-metadata">

**Author:** ![steven.burnett](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/steven.burnett/32/49261_2.png) [@steven.burnett](https://community.auth0.com/u/steven.burnett)\
**Post date:** [July 25, 2023, 10:23pm UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/5 "2023-07-25T22:23:24Z")

</div>

@marcelina.barycka It seems the call in React Native to clear the session does not work. Do you have a solution? Safari says it cannot open the URL. I don’t think what you posted is a solution given that the example app doesn’t work and the beta quick start fails on logout.

---

<div class="post-metadata">

**Author:** ![marcelina.barycka](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/marcelina.barycka/32/56162_2.png) [@marcelina.barycka](https://community.auth0.com/u/marcelina.barycka)\
**Post date:** [July 31, 2023, 9:21am UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/6 "2023-07-31T09:21:55Z")

</div>

It might be essential if the issues happens on simulators or real devices. It looks like what happened in case of the android simulator has not been the issue for a real android device. The suggested tips are a basic troubleshooting and if it still doesn’t work for the simulator in use, then it’s hard to tell what’s the issue and to bring a solution - it could be a good idea to reach out to a community that helps with the work environment in question.

Another thing you can do is to bring your observations indicating where the issue occurs (simulators a real device?) by visiting this [page](https://github.com/auth0/react-native-auth0), at the bottom there are a couple of useful links on where and how to report issues with react-native-auth0 SDK directly to its owners.

---

<div class="post-metadata">

**Author:** ![anna.s.logacheva](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/anna.s.logacheva/32/45089_2.png) [@anna.s.logacheva](https://community.auth0.com/u/anna.s.logacheva)\
**Post date:** [July 31, 2023, 11:25am UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/7 "2023-07-31T11:25:34Z")

</div>

I found an issue on github with the same problem and it was not resolved.  
Many people have the same problem and it is known issue but still not resolved.  
Do you have any other recommendations to solve this problem?

---

<div class="post-metadata">

**Author:** ![anna.s.logacheva](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/anna.s.logacheva/32/45089_2.png) [@anna.s.logacheva](https://community.auth0.com/u/anna.s.logacheva)\
**Post date:** [August 9, 2023, 3:44pm UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/8 "2023-08-09T15:44:03Z")

</div>

Do you have any other recommendations to solve this problem?

---

<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:** [August 23, 2023, 3:44pm UTC](https://community.auth0.com/t/auth0-doesnt-work-on-react-native/110454/9 "2023-08-23T15:44:46Z")

</div>

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