If you see an Error Unknown URL Scheme Android WebView, it means that the website you are trying to visit is using a URL Scheme your device does not recognize.
This error can occur in Google chrome when you are trying to open a link with an unknown URL Scheme; or when you try to open a link from an app, the link may not be compatible with your browser.
WebView is not an app or a browser. It is just a way of apps to show you webpages. It is a component of Android that allows Android applications to use website content.
Web developers build native apps that has access to web content, WebView is responsible for that as it allows web content to be displayed within the native app. Native apps are applications that are installed directly into the mobile device from Google play store, they are different from web apps. Example external links can load within your Facebook app, that is made possible with WebView.
A URL Scheme on the other hand tells you how to interpret the part of the URL after the colon(:). Apps use URL schemes to obtain resources from a website, it allows you open an app from other apps . The part which comes before the colon identifies the scheme in use, and everything after the colon is syntax specific to the scheme.
The ‘error unknown URL Scheme’ Android WebView error occurs when an Android web developer has chosen links to have an intent that is not the normal http:// or https:// that we know. There are other intents they can use like; mailto://,Whatsapp:// or any other intent they used which is unrecognized by the device.
This error has no specific solution;all Android web developers as well as Android users face this error from time to time especially when they put links without protocols. Even though developers keep patching this error, yet it resurfaces from time to time.
However, this error can only be fixed by developers. There is absolutely nothing an Android users can do to fix the issue except to notify the developers of the error and wait for them to fix it.
There are few ways you can fix this error. Sometimes prefixing your links with http:// or https:// should resolve the issue. However there are other solutions to this error.
How to fix Error-Unknown-Url-Scheme’Android WebView Error
- You can install an app called URLFixer which converts unrecognized URL schemes automatically to a URL your device can understand.
- Enable developers option on your device and set the “override software navigation” setting to ‘ON’. This will allows you enter URL manually into your device even if they use unrecognized schemes. This tip is helpful if an Android user is trying to fix the error.
- You can check the URL to see if you entered the correct URL or if the URL set to the WebView is invalid. Open in browser and check, some URLs might have illegal characters.
- You can replace Android WebView with Bromite WebView which is more stable. This can be possible if you have rooted your device.
- Another solution is to disable these schemes and develop app with http:// or https:// schemes that will be recognized by the device. Or edit the codes to be able to handle specific URL schemes.
To do this; Open a new window and add “target=” blank” which is a snippet code to your URL schemes/code, the link will now open in a new window and this error will disappear.
<a href= “tel:555-111-5555” target=”_blank”> Contact Me </a>
- Add new intent to load an external app: Intents tells Android what the app needs to do, it allows Android developers call a specific action or component. You can add an intent to load in an external app e.g. maps:// will open in your default maps application.
- Disable non standard URL schemes: this will help you bypass the error completely. You will not be able to use custom schemes, just the standard http:// or https:// protocol.
Android WebView has great benefits for Android developers, but your need to be creative to deal with certain errors like Error Unknown URL Scheme Android WebView error.
By using WebView to display an inbuilt browser within a native app, you enjoy all the benefits of a web app and a native app in one. However, when developing an app, if you need to use special URLs other than the standard http or https protocol, you need to add some intents or fill back URLs else users will experience error-unknown-url-scheme.
This article was first published on September 10, 2022 12:57 p.m. WAT
I am an experienced tech and innovation writer. It’s been 2 years+ I started writing at Terecle, covering mostly Consumer electronics and Productivity. In my spare time, I enjoy reading and learning the latest happenings around the tech ecosystem.