<!--
{
  "availability" : [
    "macOS: 27.0.0 -",
    "visionOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SpatialPreview",
  "identifier" : "/documentation/SpatialPreview",
  "metadataVersion" : "0.1.0",
  "role" : "Framework",
  "symbol" : {
    "kind" : "Framework",
    "modules" : [
      "Spatial Preview"
    ],
    "preciseIdentifier" : "SpatialPreview"
  },
  "title" : "Spatial Preview"
}
-->

# Spatial Preview

Preview spatial content from a macOS app on a connected visionOS device.

## Overview

Use Spatial Preview to work with spatial content from a macOS app to a connected visionOS device in real time.
The framework centers on two abstractions: [`SpatialPreviewEndpoint`](/documentation/SpatialPreview/SpatialPreviewEndpoint), which identifies the target visionOS device, and [`SpatialPreviewSession`](/documentation/SpatialPreview/SpatialPreviewSession), which manages the active preview connection and the flow of content.
The [`USDPreviewSession`](/documentation/SpatialPreview/USDPreviewSession) and [`DocumentPreviewSession`](/documentation/SpatialPreview/DocumentPreviewSession) objects adopt `SpatialPreviewSession` and support visionOS previews of Universal Scene Description (USD) content and general file content, respectively.
<doc://com.apple.documentation/documentation/USDKit> is recommended for Spatial Preview because it works without any additional setup.
If you want to use your own OpenUSD library, see the documentation below on how to bridge OpenUSD to <doc://com.apple.documentation/documentation/USDKit>.

## Topics

### Essentials

[Working with content from your Mac app using Spatial Preview](/documentation/SpatialPreview/working-with-content-from-your-mac-app-using-spatial-preview)

Send and update documents, and work with 3D content live from your macOS app to a visionOS device through the Spatial Preview framework.

[Bridging an external USD runtime to Spatial Preview](/documentation/SpatialPreview/bridging-an-external-usd-runtime-to-spatial-preview)

Sync edits between an app with its own OpenUSD runtime and a Spatial Preview session using a shared layer as the exchange mechanism.

### Nearby devices

[`SpatialPreviewEndpoint`](/documentation/SpatialPreview/SpatialPreviewEndpoint)

An endpoint representing a visionOS device you can connect to for spatial preview.

[`SpatialPreviewDevicePicker`](/documentation/SpatialPreview/SpatialPreviewDevicePicker)

Presents nearby companion devices and allows the user to make a selection.

[`ConnectedSpatialEndpointObserver`](/documentation/SpatialPreview/ConnectedSpatialEndpointObserver)

An observer that provides access to the endpoint for a device connected via Mac Virtual Display.

### Preview sessions

[`SpatialPreviewSession`](/documentation/SpatialPreview/SpatialPreviewSession)

A session that manages the lifecycle and connection state of a spatial preview on a visionOS device.

[`DocumentPreviewSession`](/documentation/SpatialPreview/DocumentPreviewSession)

A session that streams document content to a connected visionOS device for spatial preview.

[`USDPreviewSession`](/documentation/SpatialPreview/USDPreviewSession)

A session that enables you to present the contents of a Universal Scene Description (USD) stage.

### Session state and errors

[`SpatialPreviewSessionState`](/documentation/SpatialPreview/SpatialPreviewSessionState)

Indicates the state of the session and the health of the underlying connection.

[`SpatialPreviewSessionError`](/documentation/SpatialPreview/SpatialPreviewSessionError)

[`ConnectedSpatialEndpointObserver.UnavailableError`](/documentation/SpatialPreview/ConnectedSpatialEndpointObserver/UnavailableError)

An error thrown when accessing the [`endpoint`](/documentation/SpatialPreview/ConnectedSpatialEndpointObserver/endpoint) property while no Mac Virtual Display device is available.

[`USDPreviewSession.Error`](/documentation/SpatialPreview/USDPreviewSession/Error)

Errors that can occur during a USD preview session

[`USDPreviewSession.Event`](/documentation/SpatialPreview/USDPreviewSession/Event)

Events emitted during a USD preview session



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)