> For AI agents: the complete documentation index is available at https://rspress.rs/llms.txt, the full documentation bundle is available at https://rspress.rs/llms-full.txt.

# useSite

`useSite` returns the serialized site configuration from `rspress.config.ts`.

- **Type:** `() => { site: SiteData }`

Here is an example of getting the [title](https://rspress.rs/api/config/config-basic.md#title) configuration from `rspress.config.ts`:

```tsx preview
import { useSite } from '@rspress/core/runtime';

export default function SiteTitle() {
  const { site } = useSite();
  return <span>{site.title}</span>;
}
```

> Can be used together with [`usePage`](https://rspress.rs/ui/hooks/use-page.md) to get both global site configuration and current page metadata.
