Skip to main content

Authenticating with Oculus Rift or Quest

To enable Oculus authentication, you need to configure Oculus in the Epic Games Developer portal and enable Oculus support in your project.

Configure your Oculus app in the Oculus dashboard

In order for Oculus authentication to work, you need to enable certain permissions in the Oculus dashboard.

  1. Open the Oculus Developer Dashboard.
  2. Locate the game you want to enable authentication for. You may have two entries: one for Quest and one for Rift. If so, you will need to repeat this process for each of them.
  3. Select "API" on the left hand side.
  4. Copy the "App ID" and "App secret" values. You will need them to configure EOS and your Unreal Engine project.
  5. Select "Data Use Checkup" on the left hand side.
  6. Add the "User ID" and "User Profile" features. For the use case you can select "displaying Oculus usernames".
  7. Also add the "Friends" feature if you want to be able to display and invite Oculus friends.
  8. Click "Submit Requests" and fill out the remaining information.
  9. These features should be approved relatively quickly.
  10. Select "Distribution" -> "Release Channels" on the left hand side.
  11. Select the release channel you are uploading builds for. You must have uploaded at least one build a release channel in order for authentication to work. It is recommended you use the ALPHA channel for testing.
  12. Click on the release channel you want to use.
  13. Under the "Users" tab, click "Add Users".
  14. Enter the email address of your Oculus account.
  15. You will be sent an email inviting you to add the Oculus application to your account. Click the link in the email you get.
  16. For Rift, the application should now display in the Oculus app on Windows.

Set up Oculus authentication in the Epic Games Dev Portal

If you have both a Rift and Quest app configured, you will need to repeat this process for each.

  1. Open the Epic Games Dev Portal.
  2. Navigate to your product.
  3. Click "Product Settings".
  4. Under the "Identity Providers" tab, click "Add Identity Provider".
  5. Select "Oculus" as the identity provider.
  6. Set the "Description" to any value you like.
  7. For "Environment", select either "Rift" or "Quest" depending on which one your App ID is for.
  8. Enter the App ID and App secret values that you copied previously from the Oculus Developer Dashboard.
  9. Click "Save & Exit".
  10. Under the "Environments" tab, click "Identity Providers" next to the Live sandbox.
  11. For Oculus, add the new credential you just made. If your app is for both Rift and Quest, enable both credentials that you made.

Configure Oculus in your Unreal Engine project

If you are shipping for Oculus Rift, in your WindowsEngine.ini file, add the following configuration:

[OnlineSubsystemOculus]
bEnabled=True
RiftAppId=YOUR_RIFT_APP_ID

If you are shipping for Oculus Quest, in your AndroidEngine.ini file, add the following configuration:

[OnlineSubsystemOculus]
bEnabled=True
MobileAppId=YOUR_QUEST_APP_ID

Enable Oculus avatars, friends and invites

If you want to enable Oculus avatars, friends, synthetic parties and invites, you also need to add the subsystem to the list of delegated subsystems in WindowsEngine.ini and AndroidEngine.ini:

[EpicOnlineServices]
; This is a comma-separated list, so append ",Oculus" if you already have delegated subsystems set.
DelegatedSubsystems=Oculus
caution

You must have enabled the "Friends" feature in "Data Use Checkup" in the Oculus dashboard for friends to be displayed.

caution

In order for an Oculus friend to appear in the friends list:

  • They must be entitled to the app on the same channel as you. As an example, both you and your friend must be on the ALPHA channel.
  • They must have previously launched the game through the Oculus launcher.
  • They must have signed into EOS in the game using their Oculus account.
  • Check the Oculus and Facebook privacy settings for both users. Some settings are too restrictive for friends to appear in-game.

Use Oculus authentication at runtime

The Default authentication graph will automatically use Oculus authentication if your game is launched through Oculus (such as the Oculus Home app on Windows).

If you specifically want to use Oculus authentication, you can set the authentication graph in Project Settings to "Oculus Only", or set it in a platform-specific INI file with:

[EpicOnlineServices]
AuthenticationGraph=Oculus
caution

If you're using cross-platform accounts and you have set them as optional, then you must override how the plugin displays authentication prompts while your game is running in VR, otherwise players will not be able to interact with the "Create or sign in" prompt that will occur for new players.

Testing Oculus authentication on PC

To test Oculus authentication on your Windows PC (if you are targeting Rift), launch a standalone game with the argument -hmd=oculus. You can do this through the editor by setting standalone arguments, or through Visual Studio by setting the Command Arguments for the debugger.