Spatial Anchors
A spatial anchor is a persistent reference point in physical space that an XR system uses to keep a virtual object reliably positioned relative to the real world — across device movements, across sessions, and across multiple devices. Without spatial anchors, a virtual object placed on a real table would drift as the camera accumulates SLAM error and would disappear when the app was closed. Spatial anchors solve the persistence problem: the object stays where it was placed, session after session, device after device.
How Anchors Work
When a user places a virtual object at a location in an AR scene, the system creates an anchor at that point by recording:
- The anchor's pose (position and orientation) in the current SLAM coordinate frame
- A visual descriptor of the local environment around that point — a fingerprint of the nearby image features, surface geometry, or depth data that the system can later recognise
When the app is reopened, the system scans the environment, finds the stored visual descriptor, matches it to the current camera view, and recomputes the anchor's pose in the new session's coordinate frame. The virtual object is then placed at the re-localised anchor position rather than at a raw coordinate that would have lost meaning.
Local vs. Cloud Anchors
Local anchors persist on a single device. They are sufficient for use cases where one user wants objects to persist across their own sessions — a measurement marking, a placed piece of virtual furniture, a saved AR annotation. ARKit world anchors and ARCore anchors both support local persistence.23
Cloud anchors persist in a server-side database and can be shared across multiple devices and users. A cloud anchor is created by uploading the visual descriptor to a service; other devices can download and localise against it. This enables shared AR experiences: multiple people in the same physical space see the same virtual objects in the same positions. Azure Spatial Anchors (Microsoft) and ARCore Cloud Anchors (Google) provide cloud anchor infrastructure as managed services.13
Visual Positioning Systems
A more ambitious extension of the cloud anchor concept is the Visual Positioning System (VPS): a city-scale database of visual descriptors built from photogrammetric surveys, against which a device camera can localise to within centimetres in outdoor environments. Rather than anchoring to a specific marked location, VPS allows a device to determine its precise position anywhere within the surveyed area.
Niantic Lightship VPS (built on the Pokémon GO mapping dataset) covers thousands of publicly mapped outdoor locations globally.4 Google Maps AR navigation uses a similar indoor/outdoor VPS to place directional arrows on real streets and interiors. The practical result is persistent AR content that appears at the correct position in the physical world without the user having to scan a marker or re-establish an anchor.
Multi-User Shared Spaces
The most demanding spatial anchor use case is real-time multi-user shared AR: multiple people in the same space, each on their own device, seeing the same virtual content in the correct relative positions. This requires:
- All devices to localise to the same anchor or shared coordinate frame
- Real-time synchronisation of object states across devices (typically via a shared server or P2P connection)
- Sufficient SLAM accuracy that the localised positions across devices agree to within a few centimetres
OpenXR includes a spatial anchors extension that provides a platform-agnostic API for creating, persisting, and sharing anchors across compliant runtimes.5 As of 2024, spatial anchor persistence and sharing is supported natively in ARKit, ARCore, Meta Quest, HoloLens, and OpenXR-compliant devices, making it one of the most broadly supported persistence mechanisms in the XR ecosystem.
See also: Tracking · SLAM · Scene Reconstruction · ARKit · ARCore · OpenXR