LiveKit docs › Hooks › useMaybeSessionContext

---

# useMaybeSessionContext

> ℹ️ **Note**
> 
> This feature is under active development and may change based on developer feedback and real-world usage.

Returns the session context if it exists, otherwise undefined.

## Import

```typescript
import { useMaybeSessionContext } from "@livekit/components-react";

```

## Returns

```typescript
UseSessionReturn | undefined;

```

---

This document was rendered at 2026-06-07T11:32:56.510Z.
For the latest version of this document, see [https://docs.livekit.io/reference/components/react/hook/usemaybesessioncontext.md](https://docs.livekit.io/reference/components/react/hook/usemaybesessioncontext.md).

To explore all LiveKit documentation, see [llms.txt](https://docs.livekit.io/llms.txt).