---
title: "LocalUiMediaScope"
description: "A [UiMediaScope] provides information about the window environment and input devices, enabling
adaptive layouts and behavior. This `CompositionLocal` is the primary mechanism to access the
scope within the composable tree.

It is typically provided at the root of an application. Accessing it without a provider will
result in a runtime error."
type: "property"
---

<div class='type'>Property</div>


<a id='references'></a>

<div class='sourceset sourceset-common'>Common</div>


```kotlin
@ExperimentalMediaQueryApi
val LocalUiMediaScope =
staticCompositionLocalOf<UiMediaScope> {
    error("CompositionLocal LocalUiMediaScope not present")
}
```


A `UiMediaScope` provides information about the window environment and input devices, enabling
adaptive layouts and behavior. This `CompositionLocal` is the primary mechanism to access the
scope within the composable tree.

It is typically provided at the root of an application. Accessing it without a provider will
result in a runtime error.



