5 Benefits of WebXR
Trying to decide whether to build a WebXR or native app? Here are five reasons you might choose WebXR for.
1 - Cross Platform
With native apps, you need to decide on which platform you want to target. If you choose OpenXR, then your code will be mostly independent of the headset, but you still have to rebuild and republish for various platforms.
If you want to target Quest, you need your app to run on Android, if you want to target Windows Mixed reality, you compile/package/build for Windows. If you support HTC Vive, Valve Index or similar headsets that run on Linux, too, you would miss out on users if you don’t provide a Linux build.
All this can be solved with WebXR, which runs on the Web, an ubiquitous platform which does not care which operating system is on.
And the best part: If a new headset is released (Update 2023: like Apple Vision PRO), browsers will figure out support for it for you.
2 - Accessible
Cross platform already helps with accessibility for your users. More people will be able to access your app.
Publishing is also easier, though. Setting up a web server or hosting a static website (e.g. through GitLab Pages or GitHub Pages) is very easy!
There are no restrictions on what and when you publish.
3 - Automatic Improvement
The web is getting better every day. Not just the browsers, but the Web as a Standard is getting better, allowing you to do more on your websites.
Some upcoming improvements are WebGPU and Web Payments for example.
The former will allow for higher performance and more optimizations in 3D rendering, but also using the GPU for new use cases, like running Deep Neural Networks. The later will allow incredibly easy integration of payments on your websites.
4 - Low Entry Barrier
Since content is expected to load quickly on the web and no installation is needed, the user can be running your 3D web app in no time.
You can still allow installing your app as PWA (Progressive Web App).
5 - Rapid Development
The web is known for efficient workflows. You change an HTML file and your page is updated immediately in the browser. Hot-reloading tools speed up development times.
The 3D Web supports these workflows as well. Code based frameworks like Three.js and A-Frame work with the same tools that are used for 2D websites. Tools like Wonderland Engine provide their own hot-reloading tools that enable this rapid development workflow.
Summary
There are many reasons to choose Web over native. One of the biggest disadvantages so far is that optimizing VR apps on the Web is even harder than on native. With WebAssembly and WebGPU, the future brings the performance of Web closer and closer to native performance. In the long run, this gap will be closed.
Wonderland Engine already runs on WebAssembly and allows you to think less about optimization and instead spend your time on the app itself.
Try Wonderland Engine for free here: