---
title: Quickstart
description: Complete a verified next-ai-ready setup in about 10 minutes.
canonical_url: https://nextaiready.com/en/docs/guides/quickstart
url: https://nextaiready.com/en/docs/guides/quickstart
last_updated: 2026-11-23
updated: 2026-11-23
author: next-ai-ready team
summary: Complete a verified next-ai-ready setup in about 10 minutes.
topics: [quickstart, tutorial, getting-started]
---

# Quickstart

By the end, a GET request to `/docs/quickstart.md` returns your sample page as Markdown and the app still serves its normal HTML homepage.

This guide takes you from install to a verified AI-readable Next.js setup. Allow about ten
minutes, plus dependency downloads and the production build. Start with readable content;
callable actions and MCP are optional next steps.

Use Node.js 20+ and a Next.js 14.2+ App Router application. Keep your existing package manager.

## 1. Create a project

**Option A — new project:**

```bash
npm create next-ai-ready@latest my-site
cd my-site
npm install
npx next-ai-ready init
```

The scaffold supplies a runnable minimal App Router TypeScript app and starter MDX content. It does not pre-generate AI-ready config or handlers; the explicit `init` step adds that wiring after installation.

**Option B — existing Next.js app:** run these commands from its root. Do not create a second app.

```bash
pnpm add next-ai-ready
pnpm exec next-ai-ready init
```

Default `init` adds Knowledge Plane handlers and build wiring. It does not add Actions, MCP,
`/openapi.json`, or `/tools.json`. If your project is already initialized, keep the existing
configuration and handlers rather than forcing replacements.

## 2. Add a page and check the configuration

Create `content/docs/quickstart.mdx` with this content. The default content globs include this path.
The scaffold also includes `content/index.mdx`; keep it or replace it with your real homepage source.

```markdown
---
title: Quickstart Check
summary: Install dependencies for the example project.
---

# Quickstart Check

Run `pnpm install` from the application root to install dependencies.
```

Edit the existing `ai-ready.config.ts` or `ai-ready.config.mjs`: set `site.name`,
`site.description`, and `site.baseUrl` to your site's real identity and production origin. Do not
deploy the generated `https://example.com` placeholder. If your files live elsewhere, update the
content globs to match the original Markdown/MDX source files.

The example maps to `/docs/quickstart.md`. A file under `content/` does not create a browser page;
your current renderer remains responsible for HTML routes. Read the [MDX collection guide](./mdx-content)
if your content and browser route conventions differ.

## 3. Build and diagnose

```bash
npx next-ai-ready build
npx next-ai-ready doctor --score
```

The build should find your source files and write `.next-ai-ready/graph.json` and the discovery
files under `public/`. Counts depend on the actual content; zero routes means you need to fix the
source path or glob. Check that `public/llms.txt` links to `/docs/quickstart` on your configured origin.

`doctor` should report **0 errors**. Read and resolve or explicitly record warnings; a numeric
score alone does not prove that the public routes return the intended content.

The false missing-OpenAPI warning in Knowledge-only projects was fixed and released in alpha.22.
If you installed alpha.21, upgrade; OpenAPI remains optional, so do not enable capabilities
just to silence that warning.

## 4. Verify the running application

For the scaffold's npm workflow, build and start the production app:

```bash
npm run build
npm run start
```

Use `pnpm build` and `pnpm start` in a pnpm app. `init` adds the AI build step to the app's build
script; the separate CLI build above helps diagnose it before the full Next.js build.

In another terminal, with the server running on port 3000:

```bash
curl -i http://localhost:3000/llms.txt
curl -i http://localhost:3000/docs/quickstart.md
curl -i -H 'Accept: text/html' http://localhost:3000/
```

The setup is verified when:

- `/llms.txt` returns `200` and includes the configured `/docs/quickstart` link.
- `/docs/quickstart.md` returns `200` and `Content-Type: text/markdown`, with the `Quickstart Check`
  title and dependency-installation instructions. A recovery response containing `document_status: "not_found"`
  is not a successful page check, even when its status is `200`.
- The normal browser request to `/` still returns your app's HTML, not Markdown.

If the Markdown page is missing, check its source file, content glob, graph route, handlers, and
`withAiReady()` wiring. If links use the wrong hostname, correct `site.baseUrl` and rebuild.
For production checks, run [the public HTTP example](./nextjs-llms-txt#see-a-production-example).

## Next steps

- Read about the [Knowledge Plane](/en/docs/concepts/knowledge-plane) to understand content compilation
- Run `next-ai-ready init --with-capabilities` when you are ready to add the [Capability Plane](/en/docs/concepts/capability-plane)
- Check the [API Reference](/en/docs/api-reference/config) for full configuration options
