Launch Safari from app on iOS 14 when Safari is not the default browser using the scheme of the URL

Viewed 2621

In iOS 14, Apple has launched the feature to set any browser as default browser which is a nice feature.

If you start a local iOS app from a browser to do some action and then leave the control back to the browser you have to explicitly launch that specific browser on iOS.

To launch the default browser use https://example.com. If the user isn't using the default browser, different vendors have registered schemes to launch them, so if the browser is chrome, you use googlechromes://example.com, if it is firefox use firefox://example.com.

I cannot find how to do this for safari using a safari scheme?

You can of course use the Back-to-app functionality, but the user experience would not be very good.

1 Answers

It was true when I set Safari as a default browser. But I changed it to the other browsers like Chrome and Edge, then it was false.

Adding https & http into LSApplicationQueriesSchemes, it was the result I had hoped for.

Related