Getting Started
Learn what Nextly is and understand its core concepts.
Nextly is an open-source content platform that embeds directly into your Next.js application. Instead of running a separate server, Nextly lives alongside your frontend code -- same repo, same deployment, same database.
Two Ways to Build
Model content in TypeScript or in the Visual Schema Builder. Both feed the same Nextly runtime, admin and APIs. See Builder vs code-first for where they differ.
Code-First
Define collections and singles in TypeScript. Your content schema lives in nextly.config.ts, is version-controlled, and generates types automatically.
import { defineConfig, defineCollection, text, richText } from "nextly/config";
const posts = defineCollection({
slug: "posts",
labels: { singular: "Post", plural: "Posts" },
fields: [
text({ name: "title", required: true }),
richText({ name: "content" }),
],
// Built-in Draft/Published lifecycle: injects a `status` system column
// (default 'draft') and adds Save Draft / Publish buttons in the admin.
status: true,
});
export default defineConfig({
collections: [posts],
});Visual Schema Builder
Create and modify collections visually through the admin panel at /admin. The Visual Schema Builder lets you add fields with drag-and-drop, configure validation, and set up relationships -- all without writing config code. Collections created this way generate database tables dynamically and are immediately available through the same API. See Schema Builder for the full walkthrough.
Reading content
Model content in TypeScript or in the Visual Schema Builder. Both feed the same Nextly runtime, admin and APIs. A page reads a collection with the Direct API:
import nextlyConfig from "../../../nextly.config";
import { getNextly } from "nextly";
export default async function BlogPage() {
const nextly = await getNextly({ config: nextlyConfig });
const { items: posts } = await nextly.find({
collection: "posts",
limit: 10,
});
return (
<ul>
{posts.map((post) => (
<li key={post.id}>{post.title}</li>
))}
</ul>
);
}Core Concepts
Collections
Collections are repeatable content types -- like blog posts, products, or team members. Each collection gets its own database table and admin UI for managing entries. See Collections for the full reference.
Singles
Singles store one-of-a-kind content -- site settings, navigation menus, footer content. They work like collections but hold a single document instead of many. See Singles.
Fields
Fields define the shape of your content. Nextly ships eighteen field types organised by category:
- Basic:
text,textarea,richText,email,icon,password,code,number,checkbox,date - Selection:
select,radio,chips - Media:
upload - Relationship:
relationship - Layout:
repeater,group - Component:
component - Advanced:
json
See Fields for every option per field with examples.
Field Groups
Field groups are reusable field structures that can be embedded in collections, singles, or other field groups. Define a field group once (like an SEO block or a CTA section), then use it across multiple content types. See Field Groups.
Admin Panel
Nextly includes a full admin interface at /admin with role-based access control, a media library, and rich text editing. The admin panel works with both code-first and Visual Schema Builder content. See Admin Panel for the full overview.
Prerequisites
- Node.js
^22.12.0 || >=24.0.0(Node 20 and Node 23 are not supported) - Next.js with the App Router, and React, at the versions in Requirements
- TypeScript 5+
- A supported database: PostgreSQL (recommended for production), MySQL, or SQLite (great on your own machine and on a single server; on Vercel, choose PostgreSQL; see SQLite)
- Basic familiarity with Next.js and TypeScript
Next Steps
- Installation -- Install Nextly in your project
- Quick start -- Create a project, start it and create the first admin
- Tutorial: build a blog -- Build a blog, step by step
- Project Structure -- Understand how a Nextly project is organised
- Configuration -- Full configuration reference for collections, singles, and fields