# \`IWebBrowserSchemeHandler\` support for Android and iOS 

**URL:** <https://forums.unrealengine.com/t/iwebbrowserschemehandler-support-for-android-and-ios/2724867>\
**Category:** Mobile\
**Tags:** unreal-engine, Epic-Pro-Support, question\
**Created:** [April 28, 2026, 6:45am UTC](https://forums.unrealengine.com/t/iwebbrowserschemehandler-support-for-android-and-ios/2724867 "2026-04-28T06:45:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous-edc](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous-edc](https://forums.unrealengine.com/u/anonymous-edc)\
**Post date:** [April 28, 2026, 6:45am UTC](https://forums.unrealengine.com/t/iwebbrowserschemehandler-support-for-android-and-ios/2724867/1 "2026-04-28T06:45:29Z")

</div>

Our game requires that we provide an API for embedded web apps to interact with game data. We’d like a portion of this API to be authored as custom URL schemes that can be authored in HTML, for example - `\<img src=“my-game://image/{contentId}” /\>` would allow C++ game code to look up the corresponding asset and stream an image to the browser.

This works well on Win64 by implementing the `IWebBrowserSchemeHandler` and `IWebBrowserSchemeHandlerFactory` APIs, but unfortunately these aren’t implemented on Android and iOS.

The workaround for mobile is to either pass Base64 strings to the web page (expensive for CPU and memory) or use `file://` origins (security/CORS issues on mobile).

In `WebBrowserSingleton.cpp`, the implementation for `RegisterSchemeHandlerFactory` is wrapped with an `#if WITH\_CEF3` block. On mobile platforms, the native web view wrappers don’t consult the engine’s scheme registery, making it impossible to intercept and serve local binary data directly to a web page via a custom scheme.

Locally we’ve been able to modify the various browser-related classes to enable this natively:

1. Remove the `#if WITH\_CEF3` guard in `WebBrowserSingleton.cpp` and expose a lookup API for platform-specific widgets to query registered factories
2. Patched `SAndroidWebBrowserWidget::HandleShouldInterceptRequest` to check the scheme against the C++ registry, execute the `IWebBrowserSchemeHandler` and stream the results back into the JNI `WebResourceResponse`
3. We haven’t implemented this locally yet, but we plan to use the `WKURLSchemeHandler` protocol in `ApplePlatformWebBrowser.cpp` to bridge the native `WKWebView` requests back to the C++ registery

Before we continue investing more into this, I wanted to check to see if there are there plans on Epic side to eventually implement this behavior natively for mobile web views?

[Attachment Removed]

---

<div class="post-metadata">

**Author:** ![anonymous-edc](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous-edc](https://forums.unrealengine.com/u/anonymous-edc)\
**Post date:** [April 28, 2026, 6:45am UTC](https://forums.unrealengine.com/t/iwebbrowserschemehandler-support-for-android-and-ios/2724867/2 "2026-04-28T06:45:32Z")

</div>

**Steps to Reproduce**

1. Create a Custom Scheme Handler: Implement IWebBrowserSchemeHandler and IWebBrowserSchemeHandlerFactory in C++ and register it via IWebBrowserSingleton::RegisterSchemeHandlerFactory(TEXT(“my-game”), TEXT(“”), myFactory).
2. Verify on Desktop: Run the project on Win64/macOS. Point a UWebBrowser widget at an HTML page containing \<img src=“my-game://image/test\_portrait” /\>. Observe that the handler is invoked and the image renders.
3. Inspect Engine Code (The Root Cause): Observe that in WebBrowserSingleton.cpp, the registration logic is wrapped in #if WITH\_CEF3. The mobile native (AndroidWebBrowserWidget.cpp and ApplePlatformWebBrowser.cpp) don’t reference the SchemeHandlerFactories map at any point during their navigation or resource-loading lifecycles.
4. Deploy to Mobile: Package and run the same project on Android or iOS.
5. Observe Failure: The image fails to load. On Android, the console logs typically show an “Unknown Scheme” error; on iOS, the request is either ignored or blocked by WKWebView security policies as it does not recognize the custom scheme.  
[Attachment Removed]

---

<div class="post-metadata">

**Author:** ![step\_jac\_eg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@step\_jac\_eg](https://forums.unrealengine.com/u/step_jac_eg)\
**Post date:** [April 28, 2026, 6:28pm UTC](https://forums.unrealengine.com/t/iwebbrowserschemehandler-support-for-android-and-ios/2724867/3 "2026-04-28T18:28:40Z")

</div>

Hi Viet,

I discussed this with the WebBrowser devs and, unfortunately, there are no plans to pursue this internally. However, they would be open to looking at a PR if this is something you’d deem useful to longer term use of UE.

Best regards.

[Attachment Removed]
