question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

auth/operation-not-supported-in-this-environment on Ionic v4

See original GitHub issue

Describe your environment

  • Operating System version: ionic v4 (React) / iOS
  • Browser version: -
  • Firebase UI version: 4.2.0
  • Firebase SDK version: 6.6.0

Describe the problem

Not sure this is a bug. I cannot make Google OAuth work on a Ionic hybrid-app. The error is always the following:

auth/operation-not-supported-in-this-environment

This operation is not supported in the environment this application is running on. “location.protocol” must be http, https or chrome-extension and web storage must be enabled.

In fact, location.protocol is capacitor: in my case. On the other hand, the doc says

FirebaseUI fully supports all recent browsers. Signing in with federated providers (Google, Facebook, Twitter, GitHub, Microsoft, Yahoo, OIDC, SAML) is also supported in Cordova/Ionic environments.

First of all, does this include Capacitor environments? I only find inconsistent or outdated information.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:6
  • Comments:13 (2 by maintainers)

github_iconTop GitHub Comments

19reactions
bojeil-googlecommented, Sep 9, 2019

We do not support Capacitor environments.

12reactions
marcoanconacommented, Sep 9, 2019

I see. I will use only email authentication for now, which works like a charm. I would suggest to update the README to clarify this, because “Ionic” can be intended as “Capacitor” nowadays. Any plans to support this in the future?

Read more comments on GitHub >

github_iconTop Results From Across the Web

FIrebase Google auth operation not supported in this ...
When I run it in the browser it is working fine, but when I run it in android device I am getting auth/operation-not-supported-in-this...
Read more >
Firebase auth/operation-not-supported-in-this-environment ...
I'm having a problem with Capacitor when logging in to Firebase via GoogleAuthProvider. const provider = new firebase.auth.
Read more >
auth/operation-not-supported-in-this-environment on Ionic v4
Not sure this is a bug. I cannot make Google OAuth work on a Ionic hybrid-app. ... This operation is not supported in...
Read more >
FIrebase Google auth operation not supported in this ... - Reddit
I am developing a mobile application with ionic and firebase. The thing I want is that for the user to be confirmed he...
Read more >
Ionic 1 and Angular 1 Firebase running on iOS and Android ...
auth.AuthCredential type that was used. var credential = error.credential; });. Error: This operation is not supported in the environment this application is ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found