# Fumadocs Core (the core library of Fumadocs): Introduction
URL: /docs/headless
Source: https://raw.githubusercontent.com/fuma-nama/fumadocs/refs/heads/main/apps/docs/content/docs/headless/index.mdx

Getting started with core library

## What is this? [#what-is-this]

Fumadocs Core offers server-side functions and headless components to build docs on React.js frameworks like Next.js, React Router, TanStack Start, Waku and Astro.

- [Search](/docs/headless/search)
- Breadcrumb, Sidebar, TOC Components
- Remark/Rehype Plugins
- [MCP tools](/docs/headless/utils/mcp) for AI agents to search and read docs
- [Additional utilities](/docs/headless/utils)

<Callout title="Tip">
It can be used without Fumadocs UI, in other words, it's headless.

For beginners and normal usages, use [Fumadocs UI](/docs/ui).
</Callout>

## Installation [#installation]

Install the core package. Individual integrations may require additional dependencies, listed in their guides.

```package-install
fumadocs-core
```

For some components, a framework provider is needed:

```tsx tab="Next.js"
import type { ReactNode } from 'react';
import { NextProvider } from 'fumadocs-core/framework/next';

export function RootLayout({ children }: { children: ReactNode }) {
  // or if you're using Fumadocs UI, use `<RootProvider />`
  return <NextProvider>{children}</NextProvider>;
}
```

```tsx tab="React Router"
import type { ReactNode } from 'react';
import { ReactRouterProvider } from 'fumadocs-core/framework/react-router';

export function Root({ children }: { children: ReactNode }) {
  return <ReactRouterProvider>{children}</ReactRouterProvider>;
}
```

```tsx tab="TanStack Start"
import type { ReactNode } from 'react';
import { TanstackProvider } from 'fumadocs-core/framework/tanstack';

export function Root({ children }: { children: ReactNode }) {
  return <TanstackProvider>{children}</TanstackProvider>;
}
```

```tsx tab="Waku"
import type { ReactNode } from 'react';
import { WakuProvider } from 'fumadocs-core/framework/waku';

export function Root({ children }: { children: ReactNode }) {
  return <WakuProvider>{children}</WakuProvider>;
}
```

```tsx tab="Astro"
import { navigate } from 'astro:transitions/client';
import type { ReactNode } from 'react';
import { AstroProvider } from 'fumadocs-core/framework/astro';

// Rendered inside a React island, pass pathname and params from the Astro page.
export function Root({
  pathname,
  params,
  children,
}: {
  pathname: string;
  params: Record<string, string | undefined>;
  children: ReactNode;
}) {
  return (
    <AstroProvider pathname={pathname} params={params} navigate={navigate}>
      {children}
    </AstroProvider>
  );
}
```

Explore the APIs and components:

<Cards>
<Card title="Breadcrumb" href="/docs/headless/components/breadcrumb" description="The navigation component at the top of screen" />

<Card title="TOC" href="/docs/headless/components/toc" description="A Table of Contents with active anchor observer" />

<Card title="Source API" href="/docs/headless/source-api" description="The unified interface for handling content sources" />

<Card title="Search" href="/docs/headless/search" description="Implement document searching" />

<Card title="MCP" href="/docs/headless/utils/mcp" description="Expose page discovery, Markdown content, and search to AI agents" />
</Cards>