# CMS for Next.js: A CMS that lives inside your Next.js app.

Nextly is an open-source content platform for Next.js.

MIT licensed, self-hosted.

After a developer sets up and deploys Nextly, editors manage content and pages in the admin.

[Start building](https://nextlyhq.com/docs/getting-started/quick-start.md) · [Read the docs](https://nextlyhq.com/docs/getting-started.md)

```bash
npx create-nextly-app@alpha my-app
```

## What it does

### Model content

Model content in TypeScript or in the Visual Schema Builder. Both feed the same Nextly runtime, admin and APIs.

Model content visually on your development instance with the Visual Schema Builder.

![The Author collection in the Visual Schema Builder: its system fields, then its own fields.](https://nextlyhq.com/captures/schema-builder-light.png)

[The Visual Schema Builder](https://nextlyhq.com/docs/schema-builder.md)

### Edit content

A Lexical rich text editor with tables, code blocks with syntax highlighting, images from the media library and YouTube or Vimeo embeds.

See who else is editing a document, and take over deliberately.

![A post open in the entry editor, with its status and its languages in the document panel.](https://nextlyhq.com/captures/entry-editor-light.png)

[Fields](https://nextlyhq.com/docs/configuration.md)

### Read content

Read content straight from your database in your page code (the Direct API), or over REST.

Pages that read through Nextly’s cached queries update when their content changes.

`app/blog/page.tsx`

```tsx
import { getNextly } from "nextly";
import config from "@/nextly.config";

export default async function BlogPage() {
  const nextly = await getNextly({ config });
  const { items: posts } = await nextly.find({
    collection: "posts",
    where: { status: { equals: "published" } },
    sort: "-createdAt",
    limit: 10,
  });
  return <ul>{posts.map((p) => <li key={p.id}>{p.title}</li>)}</ul>;
}
```

[The Direct API](https://nextlyhq.com/docs/api-reference/direct-api.md)

## In the admin

- Add, remove, drag to reorder and choose the width of each dashboard card. [Docs](https://nextlyhq.com/docs/widgets.md)
- An activity feed of who created, changed or deleted entries, and a security audit trail. [Docs](https://nextlyhq.com/docs/audit-log.md)
- A media library, stored on local disk by default, or on S3 (and R2 or MinIO), Vercel Blob or UploadThing. [Docs](https://nextlyhq.com/docs/guides/media-storage.md)

## In your code

- Typed, code-defined schemas and APIs: `nextly generate:types` writes types for the collections, singles and field groups in your config. [Docs](https://nextlyhq.com/docs/configuration.md)
- Role-based permissions for each collection and action, plus field-level read and write rules in code, on a collection’s or single’s fields, fields inside field groups included. [Docs](https://nextlyhq.com/docs/permissions.md)
- Hooks in code run before and after a change, a read or a delete. [Docs](https://nextlyhq.com/docs/configuration/collections.md#hooks)
- Signed webhooks for content, media, user and form events, with retries, a delivery log, redelivery and secret rotation. [Docs](https://nextlyhq.com/docs/webhooks.md)

`nextly.config.ts`

```ts
import { defineCollection, defineConfig, richText, text } from "nextly/config";

const Posts = defineCollection({
  slug: "posts",
  admin: { useAsTitle: "title" },
  fields: [
    text({ name: "title", required: true }),
    text({ name: "slug", required: true, unique: true }),
    richText({ name: "content" }),
  ],
  status: true,
});

export default defineConfig({ collections: [Posts] });
```

`app/blog/page.tsx`

```tsx
import { getNextly } from "nextly";
import config from "@/nextly.config";

export default async function BlogPage() {
  const nextly = await getNextly({ config });
  const { items: posts } = await nextly.find({
    collection: "posts",
    where: { status: { equals: "published" } },
    sort: "-createdAt",
    limit: 10,
  });
  return <ul>{posts.map((p) => <li key={p.id}>{p.title}</li>)}</ul>;
}
```

[Try the tour](https://nextlyhq.com/nextjs-cms#tour)

A short tour, in your browser, and nothing is saved. Every control it draws is one Nextly 0.0.2-alpha.70 has; a dashed button is a tour shortcut.

## What ships today: in 0.0.2-alpha.70

- **Package:** `nextly`
- **Release:** `0.0.2-alpha.70` · 25 Oct 2026
- **Licence:** MIT
- **Runs in:** Your own Next.js app, self-hosted
- **Databases:** PostgreSQL 15+, MySQL 8+, SQLite 3.38+ for local work
- **Requires:** Node.js 22.12+ or 24+; Next.js 16 with the App Router; React 19
- **APIs:** The Direct API and REST

## Where it stops

- **The Visual Schema Builder:** Model content visually on your development instance with the Visual Schema Builder. [Docs](https://nextlyhq.com/docs/schema-builder.md)
- **Access rules and the Direct API:** The Direct API runs as trusted server code and skips access rules unless you pass `overrideAccess: false`. Called that way with no `user`, it is judged as a signed-out visitor: it can read where no rule names the read, and a create, update or delete needs a rule that allows it. [Docs](https://nextlyhq.com/docs/permissions.md)
- **Sign-in:** Sign-in for your team: email and password, sessions and API keys, stored in your own database. [Docs](https://nextlyhq.com/docs/guides/authentication.md)
- **Database versions:** PostgreSQL 15 or later, MySQL 8 or later, SQLite 3.38 or later for local work. [Docs](https://nextlyhq.com/docs/database.md)

Nextly is in alpha. APIs may change before 1.0. Pin exact versions in production.

## Questions

### Does Nextly run inside my Next.js app?

MIT licensed, self-hosted. Runs inside your own Next.js app, on your own PostgreSQL or MySQL database, or SQLite for local work.

### Do I model content in code or in the admin?

Model content in TypeScript or in the Visual Schema Builder. Both feed the same Nextly runtime, admin and APIs. Model content visually on your development instance with the Visual Schema Builder.

### Does Nextly have a GraphQL API?

No. Nextly offers REST and the Direct API.

### Is Nextly free?

Nextly is MIT licensed and self-hosted. MIT today, and no decision yet about paid offerings.

### Can a coding agent set it up?

Every new Nextly project ships with an AGENTS.md and CLAUDE.md written for coding agents.

## More of Nextly

- [Visual Page Builder](https://nextlyhq.com/page-builder): Twenty blocks out of the box, and the page renderer takes your own React blocks.
- [Localization](https://nextlyhq.com/localization): Translate collections, singles and components, with a fallback language when a translation is missing.
- [Publishing](https://nextlyhq.com/publishing): Working drafts, version history and Content Releases.
