---
title: 'Headless and API-First CMS'
url: 'https://getgrav.org/headless'
markdown: 'https://getgrav.org/headless.md'
date: '2026-08-13'
description: 'Grav is an open-source API-first CMS. A first-party REST API serves your content to any front end, with no database to run. Use it headless, use it monolithic, or use it both ways at once.'
---

Grav 2 is API-first  

#  A headless CMS with no database 

Grav 2 serves your content over a **first-party REST API** to any front end you like. Content stays as **Markdown** files on disk, so there is no database to run, no schema to migrate, and no export path to plan for later.

 [  Download Grav 2 → ](https://getgrav.org/downloads) [  Read the API post ](https://getgrav.org/blog/grav-2-api) 

 [ What you get    ](#headless-features) 

Decoupled when you want it

##  Everything you need to go headless 

API

### First-Party REST API

Not a plugin someone maintains on the side. The **API** ships with Grav, and the admin itself is built on it, so it stays honest.

AUTH

### Proper Authentication

Token auth that respects Grav’s existing permission model. The same users, groups, and access rules you already configured.

FLEXIBLE

### Headless or Not

Serve rendered pages from **Twig**, serve JSON to a **Next.js** front end, or do both from one install. You are not locked into either.

FLAT-FILE

### No Database

Content is a folder of **Markdown** and **YAML**. No database server, no connection pool, no nightly dump to worry about.

GIT

### Content in Version Control

Your content lives beside your code. Branch it, review it in a pull request, and deploy it the same way you deploy everything else.

AGENTIC

### MCP Server Included

The same API is exposed to agents through a built-in **MCP server**, with the same permissions. Nothing extra to run.

SPEED

### Sub-100ms Responses

Aggressive caching and no database round-trips. Reading a page is reading a file, which is the fastest thing a server can do.

GLOBAL

### Multi-Language Built In

Internationalization is part of the core, not an add-on. Serve the same content in every language you ship.

MEDIA

### Image Pipeline

Resize, crop, and optimize through a fluent API, with responsive images generated for you.

How it compares

##  How Grav differs from hosted headless 

01

### You own the content

Most headless platforms keep your content in their database or their cloud. In Grav it is a folder of **Markdown** on your disk. Moving off Grav is a copy, not a migration project.

02

### Nothing to operate

No database server, no managed service, no per-seat billing. A Grav install is PHP and files, so it runs on a $5 VPS or shared hosting just as happily as on a big box.

03

### Rendered pages when you want them

Pure headless means you build the front end for everything, including the marketing pages nobody wanted to rebuild. Grav renders those with **Twig** and still serves JSON to your app.

04

### Open source, MIT, free

The whole thing is **MIT** licensed with no paid tier gating the API, no request quotas, and no seat limits. Premium plugins are optional extras, never the price of entry.

Ready to build?

##  Go headless with Grav 2 

Download it, unzip it, and you have a working CMS with a **REST API** in front of it. Point your front end at the API, or keep the rendered pages and add the API where you need it.

 [  Download Grav 2 → ](https://getgrav.org/downloads) [  Browse the features ](https://getgrav.org/features)

---

## Navigation

- Previous: [Forum](https://getgrav.org/forum.md)
- Next: [Grav Media](https://getgrav.org/media.md)
