# Fumadocs (Framework Mode, TanStack Start): Static Build
URL: /docs/tanstack-start/deploying/static
Source: https://raw.githubusercontent.com/fuma-nama/fumadocs/refs/heads/main/apps/docs/content/docs/(framework)/[framework]/deploying/static.mdx

Output static website with Fumadocs.

## Setup [#setup]

By default, Fumadocs uses a server-first approach, which requires a running server.
You can output a static build by configuring TanStack Start.

A static build has no server, so these features don't work:

- The search server. Use [static search](#search) instead.
- [Ask AI](/docs/tanstack-start/integrations/llms#ask-ai), whose chat route calls the AI model.
- The [MCP server](/docs/tanstack-start/integrations/llms#mcp-server).

Middleware doesn't run either, so pages don't serve [Markdown for the `Accept` header](/docs/tanstack-start/integrations/llms#accept).

### Search [step] [#search]

#### Built-in Search [#built-in-search]

1. [Configure Search Server](/docs/headless/search/orama#static-export).
2. [Configure Search UI/Client](/docs/tanstack-start/search/orama#static).

After the configurations, your app will statically store the search indexes, and search will be computed on browser instead.

#### Cloud Solutions [#cloud-solutions]

Since the search functionality is powered by remote servers, static export works without configuration.

### Deployment [step] [#deployment]

Configure SPA mode and pre-rendering. See [SPA Mode](https://tanstack.com/start/latest/docs/framework/react/guide/spa-mode) for details.

```ts title="vite.config.ts"
import { tanstackStart } from '@tanstack/react-start/plugin/vite';
import { defineConfig } from 'vite';

export default defineConfig({
  plugins: [
    // ...other plugins
    tanstackStart({
      spa: {
        enabled: true,
        // TanStack Router will automatically crawl your pages [!code ++:4]
        prerender: {
          enabled: true,
        },
        // if you have any hidden paths that's not visible on UI, you can add them explicitly. [!code highlight:6]
        pages: [
          {
            path: '/docs/test',
          },
        ],
      },
    }),
  ],
});
```