Develop

Eye Tracking for Movement SDK for Unity

Updated: Sep 8, 2026
Eye tracking technology detects eye movements to control an avatar’s eye transformations as the user looks around. The Meta Quest Pro headset is the only device that supports this feature, utilizing the OVREyeGaze script.
Note: If you are just getting started with this Meta XR feature, we recommend that you use Building Blocks, a Unity extension for Meta XR SDKs, to quickly add features to your project.

Overview

The OVREyeGaze MonoBehaviour component provides eye tracking, or gaze, information. It retrieves eye pose data from the OVRPlugin in tracking space. When you add the OVREyeGaze component to a GameObject, it can simulate an eye, updating its position and orientation based on human eye movements. This component drives the expressiveness of both realistic and stylized characters and can select objects in a scene using raycasts. If you do not set up the necessary eye tracking permissions, tracking will not occur.
The Eye Gaze Building Block adds a left and a right eye GameObject, each already carrying OVREyeGaze, as children of the camera rig’s leftEyeAnchor and rightEyeAnchor. This gives you gaze-driven avatar eyes without wiring up components by hand.

Policies and Disclaimers

Your use of the Eye Tracking API must at all times be consistent with the Oculus SDK License Agreement and the Developer Data Use Policy and all applicable Oculus and Meta policies, terms and conditions. Applicable privacy and data protection laws may cover your use of Movement, and all applicable privacy and data protection laws.
In particular, you must post and abide by a publicly available and easily accessible privacy policy that clearly explains your collection, use, retention, and processing of data through the Eye Tracking API. You must ensure that a user is provided with clear and comprehensive information about, and consents to, your access to and use of abstracted gaze data prior to collection, including as required by applicable privacy and data protection laws.
Please note that we reserve the right to monitor your use of the Eye Tracking API to enforce compliance with our policies.
When a user enables eye tracking for your app, your app is granted access to real time abstracted gaze data, which is user data under the Developer Data Use Policy. You are expressly forbidden from using this data for Data Use Prohibited Practices in accordance with the Developer Data Use Policy. The eye tracking feature is powered by our Eye Tracking API technology.

Known issues

  • None

Integrate eye tracking

Before you begin, set up a project that supports eye tracking by following the Eye Tracking Overview. That guide configures the OVRCameraRig, the OVRManager target devices and Quest features, eye tracking support and permissions, and the Project Setup Tool. This page covers the OVREyeGaze setup that is specific to driving per-eye avatar transforms.
Note: For general prerequisites, see Movement SDK Getting Started.

Set up a character for eye tracking

  1. Choose the GameObject that will represent your character’s eyeball.
  2. Attach the OVREyeGaze component to it.
  3. Set the component’s reference frame, specify the eye (left or right), and set the confidence threshold.
  4. Enable Apply Rotation to allow real-time rotation of the eye GameObject as it tracks the corresponding eye. To allow positional adjustments, also enable Apply Position.
This component needs a reference frame in world space orientation to function correctly, aligned with the eye’s forward direction, to calculate the eye GameObject’s initial offset.
The key attributes include Confidence Threshold and Tracking Mode. If the eye tracking data falls below the set confidence threshold, the OVREyeGaze will not apply the data to the GameObject.
Tracking modes include:
  • World Space: Converts eye pose from tracking to world space.
  • Head Space: Converts eye pose from tracking to local space relative to the VR camera rig.
  • Tracking Space: Uses raw pose data from VR tracking space.

Read gaze data in a script

OVREyeGaze applies the confidence threshold itself, so a script does not repeat that check to gate the transform. Read Confidence when your own logic reacts to tracking quality, and check EyeTrackingEnabled before you act on the tracked eye transform:
using UnityEngine;

public class EyeGazeMonitor : MonoBehaviour
{
    public OVREyeGaze eyeGaze;

    void Update()
    {
        if (eyeGaze.EyeTrackingEnabled)
        {
            Debug.Log($"Eye {eyeGaze.Eye} gaze confidence: {eyeGaze.Confidence}");
        }
    }
}
Confidence is a read-only property that OVREyeGaze refreshes on each frame that delivers a valid eye pose. Eye and ConfidenceThreshold are public fields, so a script reads or sets either one.

FAQ

Do I need to apply correctives for eye tracking? Correctives are not required. Calibrate through the Meta Quest Pro OS to improve accuracy.
How does this work with realistic or stylized characters? The OVREyeGaze can animate any character’s eye. Stylized characters with larger eyes show more pronounced movements.
Is eye tracking available on both Meta Quest Pro and Meta Quest? Only Meta Quest Pro supports eye tracking.
Can I use eye tracking to emphasize specific scene areas? Yes. Raycasting driven by the eye transform’s forward direction can highlight areas of interest.
What if the user denies eye tracking permission? If permissions are not granted, the OVREyeGaze will not control the eye.
Does eye tracking provide confidence values? Yes. OVREyeGaze exposes a read-only Confidence property that ranges from 0 to 1, with higher values indicating greater reliability.

Learn more