# RecaptchaVerifier is only supported in a browser HTTP/HTTPS environment

**URL:** <https://forum.ionicframework.com/t/recaptchaverifier-is-only-supported-in-a-browser-http-https-environment/193336>\
**Category:** ionic-v3\
**Created:** [July 24, 2020, 7:07am UTC](https://forum.ionicframework.com/t/recaptchaverifier-is-only-supported-in-a-browser-http-https-environment/193336 "2020-07-24T07:07:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![CHAEN](https://avatars.discourse-cdn.com/v4/letter/c/87869e/32.png) [@CHAEN](https://forum.ionicframework.com/u/CHAEN)\
**Post date:** [July 24, 2020, 7:07am UTC](https://forum.ionicframework.com/t/recaptchaverifier-is-only-supported-in-a-browser-http-https-environment/193336/1 "2020-07-24T07:07:49Z")

</div>

Hello. I am writing a program that takes a 6 digit code using firebase (about authentication).  
In my Android environment, my code works so I can get a 6 digit code and log in, but in the ios environment I get an error.

RecaptchaVerifier is only supported in a browser HTTP/HTTPS environment.

How can i solve it?

It’s part of my code.

```auto
export class CertifiedPage {

  recaptchaVerifier;
  confirmationResult: firebase.auth.ConfirmationResult;
  otpSent = false;
  phoneNumber: number;
  otp: any;
  pNumber: any;
  name = '';
  mycountry = '';

  firemain = firebase.database().ref();
  constructor(public navCtrl: NavController, public alertCtrl: AlertController, public af: AngularFireAuth, public zone: NgZone) {

  }

  ionViewDidLoad() {
    this.recaptchaVerifier = new firebase.auth.RecaptchaVerifier('recaptcha-container', {
      'size': 'invisiable'
    });
  }

  sendOTP() {
    console.log('sendotp');
    this.pNumber = String(this.phoneNumber);
    this.pNumber = this.mycountry + this.pNumber;
    var iosNumber = String(this.phoneNumber);
    iosNumber = this.mycountry + iosNumber.replace(/(^0+)/, "");
    console.log(iosNumber);
    console.log(this.phoneNumber)
    console.log(this.mycountry)
    console.log(this.pNumber);
    this.af.auth.signInWithPhoneNumber(iosNumber, this.recaptchaVerifier).then((result) => {
      this.otpSent = true;
      this.confirmationResult = result;
      this.create_alert('phone', 'ok')
    }).catch(err => {
      alert(err);
      console.log(err);
    })
  }

  verifyOTP() {
    console.log('verifyotp')
    this.otp = '' + this.otp
    this.confirmationResult.confirm(this.otp).then(() => {
      this.create_alert('phone', 'ok')
      localStorage.setItem('phone', String(this.phoneNumber));
      this.userdataupdate()
    }).catch(err => {
      alert(err);
    })
  }

```

---

<div class="post-metadata">

**Author:** ![rapropos](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/rapropos/32/100227_2.png) [@rapropos](https://forum.ionicframework.com/u/rapropos)\
**Post date:** [July 25, 2020, 6:30pm UTC](https://forum.ionicframework.com/t/recaptchaverifier-is-only-supported-in-a-browser-http-https-environment/193336/2 "2020-07-25T18:30:05Z")

</div>

The very first search result I see when feeding your error message into Google leads to [this bug discussion](https://github.com/firebase/firebaseui-web/issues/145), of which a cursory examination indicates you’re going to have to look for other strategies.

---

<div class="post-metadata">

**Author:** ![DrDaxter](https://avatars.discourse-cdn.com/v4/letter/d/b5a626/32.png) [@DrDaxter](https://forum.ionicframework.com/u/DrDaxter)\
**Post date:** [October 27, 2021, 2:30pm UTC](https://forum.ionicframework.com/t/recaptchaverifier-is-only-supported-in-a-browser-http-https-environment/193336/3 "2021-10-27T14:30:30Z")

</div>

Hi, did you fix that issue?
