Embed Unreal in a host application

The applications for Unreal Engine are growing beyond games. For example, it has applications in architecture, industrial design, education, and marketing. Yet, Unreal is basically its own operating system optimized for games, and it wants to handle everything, from rendering to UI. These new application areas already have their own frameworks and applications. An alternative approach is to embed Unreal Engine views within a host application, and implement other components of the app with host OS native components, frameworks and tools. I want the best of both worlds. I want Unreal’s incredible visuals and interaction integrated with all the features offered by OS native user interfaces, libraries and components.

The request: add a mechanism for embedding Unreal Engine within native host views on macOS, iOS, Android and Windows. The engine would be packaged as framework that we link into the host application, with native view implementations that we add to our application windows, and methods for bootstrapping the engine and loading specific levels and content within the view.

For example, I am building tools for simulating and visualizing realtime biomolecular models, using Unreal Engine for the rendering and simulation components. However, Unreal Engine and UMG are not the appropriate tools for building the other components of the application. Ideally, I would like to embed Unreal in a UIView, within a larger iOS application.

@rooseveltrp is interested in a similar feature.

This may already be possible and if not I am interested in modifying the engine source to achieve the feature request. Before I dive down this rabbit hole, does anyone have any experience or pointers for achieving this? Perhaps I can build Unreal as a framework, my project as another framework, and link everything together in the host application? Unreal basically has to bootstrap itself with host-OS code when it starts up.

Looks like UE 5 may have support for this. In the early access code:

        <member name="F:UnrealBuildTool.IOSProjectSettings.bBuildAsFramework">
            Whether to build the iOS project as a framework.
        <member name="F:UnrealBuildTool.IOSProjectSettings.bGenerateFrameworkWrapperProject">
            Whether to generate a native Xcode project as a wrapper for the framework.

There’s also experimental support in UE 4.27, but I haven’t tested this out yet. If you go to Project Settings, there is checkbox “Build project as a framework (experimental)” under iOS.


Really interesting finding @programmarchy !

Did you find anything else or was able to test it in Xcode?