Skip to main content

Set up Meta Quest as an identity provider

Last updated on August 5, 2026

Overview

This guide helps verified Meta Quest developers to connect Meta Quest Accounts to AccelByte Gaming Services (AGS). You may need to set up additional features within Meta Quest services. For more information about setting up Meta Quest services, we recommend contacting your Meta representative and reviewing Meta Quest documentation.

important

This guide is intended for public use and contains limited information due to confidentiality. We recommend you refer to the full confidential guide first. Contact your AccelByte Technical Producer to request a copy of the guide.

Goals

  • Enable the Meta Quest authentication method for your game with the AGS SDK.
  • Enable the Meta Quest authentication method for your publisher website with the AGS Player Portal.

Prerequisites

Web login integration

  • You must have a verified Meta Quest Developer account.
  • You have an AGS Admin Portal account to set up authentication and manage permissions.
  • If you have not done so already, set up a Publisher Namespace for your Player Portal and Launcher.
  • You have a Player Portal.

In-game login integration

  • You must have a verified Meta Quest Developer account.
  • For Unreal Engine, you need to have the OnlineSubsystem Oculus plugin activated.
  • For Unity, you need the Oculus Unity Integration. You can find that in Oculus Integration | Integration | Unity Asset Store.
  • You have an AccelByte Admin Portal account to set up authentication and manage permissions.
  • If you have not done so already, set up a Game Namespace for your game.
  • You have a Unity or Unreal Engine game project with the latest version of the AccelByte Game SDK imported.
  • Familiarity with AGS Identity and Access Management (IAM) Clients.

Set up Meta Quest

Set up Meta Quest application

Set up the Meta Quest application on your Meta Quest developer account. Follow Meta's Create an App Page guide.

Meta Quest request platform feature

After you finish creating the application, request a data use checkup to get access to certain user data, such as user ID, user profile, and avatar. Follow the Submitting a DUC Guide steps on Meta's Data User Checkup guide.

note

If you have trouble setting up on the Meta Quest Developer Portal, contact customer support to request a copy of the available guide from AccelByte.

Set up Meta Quest login method

Web login

AGS Public Cloud

Web login integration is currently unavailable in AGS Public Cloud and is only supported in AGS Private Cloud.

To enable your players to log in to your Player Portal using their Meta Quest accounts, follow these steps:

  1. In the AGS Admin portal, go to your publisher namespace.

  2. On the sidebar menu, go to Foundations > 3rd Party Integrations > Auth & Account Linking.

  3. On the Auth & Account Linking page, click + Add New button.

    Image shows the +Add New button on the Auth & Account Linking page

  4. On the Select login provider page, from the Gaming Platform tab, select Meta Quest Web.

    Image shows the Meta Quest Web card on the Select login provider page

  5. The Set Up Meta Quest Web login provider dialog appears. Fill in the following fields:

    • Platform ID: oculusweb. Set automatically. Cannot be changed.
    • Client ID: Your Meta Quest App ID.
    • Client Secret: Your Meta Quest App Secret.
    • Organization ID: Your Meta Quest Organization ID.
    • Redirect URI: <BASE_URL>/auth/platforms/oculusweb. Replace <BASE_URL> with your domain address, e.g., https://development.accelbyte.io. Also register the following as allowed redirect URIs in the Meta Quest developer console:
      • <BASE_URL>/auth/platforms/oculusweb
      • <BASE_URL>/iam/v3/public/namespaces/<Namespace>/users/me/platforms/oculusweb/web/link/establish (used for account linking)

    Image shows the Set Up Meta Quest Web login provider dialog

  6. Click Add & Activate to create and activate the provider in one step. Alternatively, click Add to create without activating.

Edit a login provider

  1. On the Auth & Account Linking page, click the Meta Quest Web entry.

  2. A dialog appears with the provider's configuration. Update the fields as needed.

    Image shows the Meta Quest Web login provider dialog with the Active toggle

  3. Use the Status toggle at the top to activate or deactivate the provider.

  4. Click Save.

In-game login

To enable your players to log in from in-game using their Meta Quest accounts, follow these steps. The Meta Quest SDK provider is available in game namespaces on both Shared Cloud and Private Cloud.

  1. In the AGS Admin portal, go to your game namespace.

  2. On the sidebar menu, go to Foundations > 3rd Party Integrations > Auth & Account Linking.

  3. On the Auth & Account Linking page, click + Add New button.

    Image shows the +Add New button on the Auth &amp; Account Linking page

  4. On the Select login provider page, from the Gaming Platform tab, select Meta Quest SDK.

    Image shows the Meta Quest SDK card on the Select login provider page

  5. The Set Up Meta Quest SDK login provider dialog appears. Fill in the following fields:

    • Platform ID: oculus. Set automatically. Cannot be changed.
    • Client ID: Your Meta Quest App ID.
    • Client Secret: Your Meta Quest App Secret.

    Image shows the Set Up Meta Quest SDK login provider dialog

  6. Click Add & Activate to create and activate the provider in one step. Alternatively, click Add to create without activating.

Edit a login provider

  1. On the Auth & Account Linking page, click the Meta Quest SDK entry.

  2. A dialog appears with the provider's configuration. Update the fields as needed.

    Image shows the Meta Quest SDK login provider dialog with the Active toggle

  3. Use the Status toggle at the top to activate or deactivate the provider.

  4. Click Save.

Create an IAM client

An IAM client is a representation of the game client that you want to release on your target platform. Learn more about IAM Clients in Manage access control for applications.

In-game login integration

The setup for each game engine is different. Follow the steps applicable to your game engine.

Unreal in-game login integration

You can integrate Meta Quest to sign in with AccelByte SDK to enable your players to log in to games with Meta Quest credentials.

Unreal Engine preparation and configuration

Add dependency

  1. Add public dependency modules called OnlineSubsystem, OnlineSubsystemOculus, and LibOvrPlatform to your Build.cs file. These dependencies are needed for your project to use the Oculus online subsystem from Unreal Engine.

    public ABThirdPartyLogin(ReadOnlyTargetRules Target) : base(Target)
    {
    PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs;

    PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "OnlineSubsystem", "OnlineSubsystemUtils",
    "OnlineSubsystemOculus","LibOVRPlatform",
    "Sockets", "Networking", "InputCore", "AccelByteUe4Sdk", "Json", "JsonUtilities", "Http", "WebSockets"
    });

    PrivateDependencyModuleNames.AddRange(new string[] { });
    PrivateDependencyModuleNames.Add("OnlineSubsystem");
  2. You also need to add OnlineSubsystemOculus inside TutorialProject.Target.cs and TutorialProjectEditor.Target.cs.

    public ABThirdPartyLoginTarget( TargetInfo Target) : base(Target)
    {
    Type = TargetType.Game;
    DefaultBuildSettings = BuildSettingsVersion.V2;
    ExtraModuleNames.AddRange( new string[] { "ABThirdPartyLogin", "OnlineSubsystem", "AccelByteUe4Sdk", "OnlineSubsystemOculus" } );
    }
    public ABThirdPartyLoginEditorTarget( TargetInfo Target) : base(Target)
    {
    Type = TargetType.Editor;
    DefaultBuildSettings = BuildSettingsVersion.V2;
    ExtraModuleNames.AddRange( new string[] { "ABThirdPartyLogin", "OnlineSubsystem", "AccelByteUe4Sdk", "OnlineSubsystemOculus" } );
    }

Unreal Engine project setting for Meta Quest

Inside your DefaultEngine.ini file, you need to add several variables of Meta Quest configuration. You need this configuration to open the project. By default, Meta Quest initiates automatically. If you develop a rift app, make sure you're using RiftAppId=[YourAppId]. Otherwise, you can use OculusAppId=[YourAppId].

[OnlineSubsystem]
DefaultPlatformService=Oculus

[OnlineSubsystemOculus]
bEnabled=true
RiftAppId=[YourAppId]

Unreal Engine sample code implementation

Learn how to integrate Meta Quest Login Integration into your game with our SDK. Our logic is to override a player's login when they log in with Meta Quest and use the AGS platform to provide services our SDK can access.

The project uses Meta Quest as a platform so players can log in with Meta Quest credentials.

note

To obtain AccelByteOnlineSubsystemPtr used in snippet, follow this guide.

  1. Ensure you call the online identity function for getting platform_tokens once Meta Quest does an entitlement pass.

    const IOnlineSubsystem* OnlineSubsystem = IOnlineSubsystem::Get();
    if (OnlineSubsystem == nullptr)
    {
    FString Message = TEXT("Cannot login with no online subsystem set!");
    UE_LOG(LogTemp, Warning, TEXT("%s"), *Message);
    OnActionInfoUpdated.Broadcast(Message);
    return;
    }

    const IOnlineIdentityPtr OnlineIdentity = OnlineSubsystem->GetIdentityInterface();
    if (!OnlineIdentity.IsValid())
    {
    FString Message = TEXT("Could not retrieve identity interface from native subsystem.");
    UE_LOG(LogTemp, Warning, TEXT("%s"), *Message);
    OnActionInfoUpdated.Broadcast(Message);
    return;
    }
  2. Once the system retrieves the platform_token, it uses the token to call the AccelByte loginWithOtherPlatform API. The code looks like this:

    const FOnLoginCompleteDelegate NativeLoginComplete = FOnLoginCompleteDelegate::CreateLambda([=]
    (int32 LocalUserNum, bool bWasSuccessful, const FUniqueNetId& UserId, const FString& Error) {
    UE_LOG(LogTemp, Warning, TEXT("OnLoginComplete %s : %s"), bWasSuccessful ? TEXT("Success") : TEXT("Fail"), *Error);
    FString Message = FString::Printf(TEXT("OnLoginComplete %s : %s"), bWasSuccessful ? TEXT("Success") : TEXT("Fail"), *Error);
    OnActionInfoUpdated.Broadcast(Message);

    if (bWasSuccessful)
    {
    auto OculusUserId = OnlineIdentity->GetUniquePlayerId(0);
    auto GenAuth = OnlineIdentity->GetAuthToken(LocalPlayer->GetControllerId());
    const FString PlatformToken = (TEXT("%s:%s"), OculusUserId, GenAuth);
    UE_LOG(LogTemp, Warning, TEXT("PlatformToken : %s"), *PlatformToken);
    OnActionInfoUpdated.Broadcast(FString::Printf(TEXT("PlatformToken : %s"), *PlatformToken));

    auto ApiClient = AccelByteOnlineSubsystemPtr->GetApiClient(TEXT("YOUR_KEY"));
    auto UserApi = ApiClient->GetUserApi().Pin();

    UserApi->LoginWithOtherPlatform(EAccelBytePlatformType::Oculus, PlatformToken, OnLoginSuccessDelegate, OnLoginErrorDelegate);
    UE_LOG(LogTemp, Warning, TEXT("Request LoginWithOtherPlatform"));
    OnActionInfoUpdated.Broadcast(TEXT("Request LoginWithOtherPlatform"));
    }
    });
    OnlineIdentity->AddOnLoginCompleteDelegate_Handle(LocalPlayer->GetControllerId(), NativeLoginComplete);
    const bool bWaitForDelegate = OnlineIdentity->Login(LocalPlayer->GetControllerId(), FOnlineAccountCredentials());
    if (!bWaitForDelegate)
    {
    FString Message = TEXT("The online subsystem couldn't login");
    UE_LOG(LogTemp, Warning, TEXT("%s"), *Message);
    OnActionInfoUpdated.Broadcast(Message);
    }
    note

    The platform_token for Meta Quest Authentication is <oculus_user_id>:<nonce_value>.

    Ensure you are calling the right platform in this code: EAccelBytePlatformType::Oculus.

    UserApi->LoginWithOtherPlatform(EAccelBytePlatformType::Oculus, PlatformToken, OnLoginSuccessDelegate, OnLoginErrorDelegate);

Sample code testing

Launch arguments

Launch your project by running it in the editor, or use this executable command with the Command Prompt or Powershell.

"[[PathToUE5Folder]]\Epic Games\UE_5.0\Engine\Binaries\Win64\UnrealEditor.exe]" "[PathToProjectFolder]\TestingUnreal\ABThirdPartyLogin\ABThirdPartyLogin.uproject" -skipcompile -game

The image below shows a successful login to our test app using a Meta Quest account.

Image shows sample code for Unreal code testing

Note

There are two types of user ids in Meta Quest:

  • app scoped id: unique ID per application, different for the same application on different devices, can be avoid by app grouping, in the same app grouping, new users will have the same app scoped id, for games that want to share user data between devices, please put the apps in the same app group.
  • organization scoped id: unique per organization, allows different apps within the same organization to identify the user.

For AGS account link, we use organization scoped id so that we can identify the same Meta Quest account regardless of the apps within this organization.

We also utilize the app scoped id for some features like IAP.

You can get the app scoped id by an AGS user id with this endpoint.

You can get the AGS user account by the app scoped id with this endpoint.