iOS 17.1 breaks Sign-In with Apple (JavaScript) within WKWebView

We've noticed that under iOS 17.1 we get different behaviour with Sign-In with Apple.

We have implemented the Sign-In with Apple button using Apple's approved JavaScript method and placed this on an HTML page within the App's WKWebView.

Expected behaviour : the user is presented with the native Sign-In popover sheet and can use FaceID or TouchID to sign-in.

Actual Behaviour : in 17.0.3 it works as expected but in 17.1 we go to a standard HTML log-in with Apple form.

Most confusing. Any ideas?

Accepted Reply

Worked in version "17.0.3", doesn't work in version "17.1"

Anyone able to shed light on this?

Replies

Worked in version "17.0.3", doesn't work in version "17.1"

Anyone able to shed light on this?

I have the same problem!

Also fails with iOS 17.2 Beta.

Hey @apple any ideas on this? Same codebase works fine in 17.0.3 but not in newer versions. Thus I don't think this is anything we're doing within JS or Swift, nor anything in the back-end setup. Help!

I have the same problem!

Some issues here. Has anyone found any fix

I found a solution, completely abandon js and rewrite it to swift

  • Not a solution =) Apple has provided the functionality and declares it so far in its documentation. However, it doesn't work(

Add a Comment

This issue is blocking usage of our app. Apple sign in no longer works in WKWebView under iOS 17, even though it is possible to sign into the website via Apple login on the same device.

Yes, we have to same problem. The html popup window is also empty when you use the "usePopup: true" setting. However, when you use "usePopup: false", the non-native html logon window will function properly. Similar to when Firefox or Chrome is used to login.

We have found the solution.

You need to setup app links, set usePopup to false, and open the appleid logon page in Safari instead of the WkWebview of your app.

Then after logging on or signing up, the redirect url will be openend in Safari. It will ask the user if you want to open the url in the app. When you do this, the id_token will be passed to the app and you will be able to logon or signup the user.

For a more user friendly experience we are going to implement it a little bit differently. The redirect, complete with signup or logon, will be handled by safari. The user will be shown a page with readable status information and offered a one time handoff link to go back to the wkwebview of the app.

Fixed in iOS 17.2.

I am using 17.2.1 still facing the same issue.