{ "collection": "pages", "slug": "pricing",
"frontmatter": { "title": "Pricing" } }Content is code. Skip the dashboard.
Most of us already ship with agents more than by hand. Graft keeps content as code so you and your agent can author, branch, and deploy without living in a dashboard.
§01 the loop
Edit a file. Compile. Refresh.
No publish button and no admin write path. You or your agent change MDX; graft compile validates it and updates the Postgres index.
- author
- validate
- index
- typed read
- render
If git and Postgres disagree, recompile. Git wins. The index is derived state.
§02 no dashboard trap
Dashboards lock agents out.
A mouse UI is a dead end for an agent. Graft speaks MCP and CLI with errors that carry their own fix. This replay is a real cold exchange.
§03 typed reads
One schema. No codegen.
The Zod schema in graft.config.ts types the compiler, the SDKs, the functions, and the MCP tools.
§04 self-host
Your Postgres. Your box.
Open source and self-hostable. One container, or graft serve against your database. Same handler bytes either way. No Graft cloud required.
Deploy anywhere. Railway, Fly, VPS, or embed the handlers in Next, Astro, SvelteKit, TanStack Start, or React Router.
§05 branching
Branch content the way you branch code.
Copy-on-write overlays on any Postgres, or Neon forks when you want a physical database. Merge dry-runs first. Pick a step:
A registry row. Nothing copied.
A branch is an edge off main. Instant and isolated. Reads fall through the overlay until something writes.
§06 faq — served from content_index
Common questions
Do I need a dashboard?
No. Write MDX, run the CLI, or drive MCP, and nothing else has to be running. A Studio ships in the box for the people who want one: run graft studio to edit content, decide approvals, and browse branches. It is optional, and every operation it performs also exists on the CLI and on MCP.
Is Graft open source and self-hostable?
Yes. Run the packages on your Postgres and S3-compatible store. One Docker image, split compose, or handlers embedded in your app. No Graft cloud required.
Is content stored in git?
Yes. Git owns authored content. Postgres holds a derived index. If they disagree, recompile. Git wins.
Who is this for?
You and your agent. Agents do most of the edits through MCP and the CLI. You own the repo, review diffs, and decide destructive gates.
How do I add a feature vertical?
Run graft add commerce (or comments, seo, faq). Source lands under graft/ as TypeScript you own. No plugin black box.
begin
Drop Graft onto your repo.
You scaffold. Your agent authors.
Open source and self-hostable. One command writes graft.config.ts and the first MDX doc. You and a cold agent share the same loop: compile, branch, merge. No admin login.
Claude
Cursor
Codex
Copilot
Gemini
For your agent
Connect MCP or the CLI.
Tool descriptions and error fix fields teach the loop. Claude, Cursor, Codex, Copilot, Gemini — anything that speaks MCP.
For you
Scaffold the repo.
One command. Config and the first document: files you own on your machine.