---
title: RemoteDeviceIdentifier
framework: swiftui
role: symbol
role_heading: Structure
path: swiftui/remotedeviceidentifier
---

# RemoteDeviceIdentifier

An opaque type that identifies a remote device displaying scene content in a RemoteImmersiveSpace.

## Declaration

```swift
struct RemoteDeviceIdentifier
```

## Overview

Overview Access this from the remoteDeviceIdentifier environment property in a remote scene to get the identifier for that scene’s device. When accessed in a context that is being presented on the local device, this value will be nil. This identifier can also be used to initialize an ARKitSession associated with the remote device. struct SolarSystem: CompositorContent {     @Environment(\.remoteDeviceIdentifier) private var deviceID

var body: some CompositorContent {         RemoteImmersiveSpace {             CompositorLayer { layerRenderer in                 // Create an ARSession for the device                 let arSession = ARKitSession(deviceID)

// Set up and run the Metal render loop.                 let renderThread = Thread {                     let engine = solar_engine_create(                         layerRenderer, arSession)                     solar_engine_render_loop(engine)                 }                 renderThread.name = "Render Thread"                 renderThread.start()             }         }     } } note: This identifier is not stable across app launches.

## Topics

### Instance Properties

- [cDevice](swiftui/remotedeviceidentifier/cdevice.md)

## Relationships

### Conforms To

- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Handling remote immersive spaces

- [RemoteImmersiveSpace](swiftui/remoteimmersivespace.md)
