Deploying to Android
Setup
Most standalone headsets run on Android and OpenXR support is making its way to these platforms.
Before following the OpenXR-specific instructions here, you'll need to first setup your system to export to Android in general, including:
Installing OpenJDK 17
Installing Android Studio
Configuring the location of the Android SDK in Godot
SeeExporting for Android for the full details, and return here when you've finished these steps.
Warning
While the Mobile Vulkan renderer has many optimizations targeted at mobile devices, we're still working out the kinks.It is highly advisable to use the compatibility renderer (OpenGL) for the time being when targeting Android based XR devices.
Gradle Android build
Note
Official support for the Android platform wasn't added to the OpenXR specification initially resulting in various vendors creating custom loaders to make OpenXR available on their headsets.While the long term expectation is that all vendors will adopt the official OpenXR loader, for now these loaders need to be added to your project.
In order to include the vendor-specific OpenXR loader into your project, you will need to setup a gradle Android build.
SelectInstall Android Build Template... from theProject menu:

This will create a folder calledandroid inside of your project that contains all the runtime files needed on Android. You can now customize this installation. Godot won't show this in the editor but you can find it with a file browser.
You can read more about gradle builds here:Gradle builds for Android.
Installing the vendors plugin
The vendors plugin can be downloaded from the asset library, search for "OpenXR vendors"and install the one named "Godot OpenXR Vendors plugin for Godot 4.3".

You will find the installed files inside theaddons folder. Alternatively youcan manually install the vendors plugin by downloading itfrom the release page here.You will need to copy theassets/addons/godotopenxrvendors folder from the zipfile into your projectsaddons folder.
You can find the main repository of the vendors pluginhere.
Creating the export presets
You will need to setup a separate export preset for each device, as each device will need its own loader included.
OpenProject and selectExport...Click onAdd.. and selectAndroid.Next change the name of the export preset for the device you're setting this up for, sayMeta Quest.And enableUse Gradle Build.If you want to use one-click deploy (described below), ensure thatRunnable is enabled.
If the vendors plugins were installed correctly you should find entries for thedifferent headsets underXR Features. Change theXR Mode toOpenXR, thenselect the entry for your headset if you see one. If you don't see one enable theKhronos plugin.

Scroll to the bottom of the list and you'll find additional XR feature sections,currently onlyMeta XR Features,Pico XR Features,Magicleap XR FeaturesandKhronos XR Features for HTC are available. You will need to select theappropriate settings if you wish to use these features.
Running on your device from the Godot editor
If you've setup your export settings as described above, and your headset is connected to your computer and correctly recognized, you can launch it directly from the Godot editor usingOne-click deploy:

For some devices on some platforms, you may need to perform some extra steps in order for your device to be recognized correctly, so be sure to check the developer documentation from your headset vendor.
For example, with the Meta Quest 2, you need to enable developer mode on the headset, and if you're on Windows, you'll need to install special ADB drivers. See theofficial Meta Quest developer documentation for more details.
If you're having any issues with one-click deploy, check theTroubleshooting section.