Google is committed to advancing racial equity for Black communities. See how.

Enable ARCore

Before you start developing augmented reality experiences for your app, you must enable ARCore functionality in your Unity project. To do this, you need to:

  1. Install Unity 2019.4.3f1 or later
  2. Have a working project using AR Foundation
  3. Install the ARCore Extensions package
  4. Configure your app to be AR Required or AR Optional
  5. Perform runtime checks
  6. Configure your app to be Depth Required or Depth Optional
  7. Ensure that your app complies with ARCore's user privacy requirements

Configure your app to be AR Required or AR Optional

An app that supports AR features can be configured in two ways: AR Required or AR Optional.

An AR Required app cannot function without ARCore. It needs an ARCore supported device that has ARCore, also known as Google Play Services for AR, installed on it.

  • The Google Play Store makes AR Required apps available only on devices that support ARCore.
  • When users install an AR Required app, the Google Play Store automatically installs Google Play Services for AR. However, your app must still perform additional runtime checks in case Google Play Services for AR must be updated or has been manually uninstalled.

An AR Optional app uses ARCore to augment a different functionality. It has optional AR features, which are activated only on ARCore supported devices that have Google Play Services for AR installed.

  • AR Optional apps can be installed and run on devices that don't support ARCore.
  • When users install an AR Optional app, the Google Play Store will not automatically install Google Play Services for AR with the app.
AR RequiredAR Optional
AR Feature usage Your app needs ARCore for basic functionality. ARCore augments your app's functionality. Your app can run without ARCore support.
Play Store visibility Your app is only listed in the Play Store on devices with ARCore support. Your app follows normal listing procedures.
Google Play Services for AR installation method The Play Store installs Google Play Services for AR alongside your app. Your app uses ARSession.state to download and install ARCore.
Android minSdkVersion requirements 24 (Android 7.0) 18 (Android 4.3)
Must use ARSession.state to check ARCore support and install status

For more information, see our app distribution overview.

Make your app AR Required

Android:

  1. Navigate to Edit > Project Settings > XR Plug-in Management > ARCore. Requirement is set to Required by default.

  2. Click Edit > Project Settings > Player, select the tab with the Android icon. Under Other Settings > Identification specify a Minimum API Level that is 24 or higher.

iOS:

  1. Navigate to Edit > Project Settings > XR Plug-in Management > ARKit. Requirement is set to Required by default.

  2. Click Edit > Project Settings > Player, select the tab with the Android icon. Under Other Settings > Identification specify a Minimum API Level that is 24 or higher.

Make your app AR Optional

  1. Select Optional from the Requirement drop-down menu to set an app to AR optional.

    Android:

    iOS:

  2. Click Edit > Project Settings > Player, select the tab with the Android icon. Under Other Settings > Identification specify a Minimum API Level that is 18 or higher.

Perform runtime checks

During runtime, AR Required apps will automatically perform runtime checks to ensure that the target device:

  • Supports ARCore
  • Has installed Google Play Services for AR — if this is not installed (possibly because it was removed by the user) or the version is too old, your app will prompt the user to install or update it.
  • Has up-to-date ARCore device profile data — if it is out of date, your app will download new data.

Set ARSession.attemptUpdate to false to disable these default checks. Your app should still handle these conditions:

Condition Action
Device does not support ARCore. Hides AR-related functionality.
Device supports ARCore, but Google Play Services for AR and/or ARCore device profile data is not installed or out of date. Prompts the user to install or update Google Play Services for AR and/or ARCore device profile data by calling ARSession.Install().
Device supports ARCore and Google Play Services for AR and ARCore device profile data is installed and up to date. Creates an ARCore Session and starts using ARCore.

You can also check the ARSession.state for installation and support states.

Configure your app to be Depth Required or Depth Optional (Android only)

If your app requires Depth API support, either because a core part of the AR experience relies on depth, or because there's no graceful fallback for the parts of the app that use depth, you may choose to restrict distribution of your app in the Google Play Store to devices that support the Depth API.

Make your app Depth required

To make your app AR Required, navigate to Edit > Project Settings > XR Plug-in Management > ARCore. Depth is set to Required by default.

Make your app Depth optional

Select Optional from the Depth drop-down menu to set an app to Depth optional.

Privacy requirements

Make sure that your app complies with ARCore's user privacy requirements.

Next steps