---
title: "CMS for a React app: what to check before you pick one for Vite or Lovable"
description: "A React CMS for a Vite app keeps your words in repo files, a headless CMS your pages fetch, or your components. How each works on a Vite, Lovable or Bolt site."
author: "Vimanyu Aggarwal"
date: "2026-08-31"
canonical: "https://vunora.ai/blog/cms-for-a-react-app"
---

# CMS for a React app: what to check before you pick one for Vite or Lovable

![Old wooden letterpress type blocks set in rows in a wooden tray](https://vunora.ai/blog/cms-for-a-react-app.jpg)

A React CMS has to answer one question before any other: where do your words load? A React app built with Vite ships as static files, so a CMS can reach its words at two moments only. Vite can build them into the app from files in your repo. Or the browser can fetch them from a headless CMS each time a page opens. There is a third place too, the one most sites built with Lovable or Bolt already use: the words sit inside the components. Pick the CMS that fits where your words are today and who will edit them.

## What makes a React app built with Vite different

A Vite app has no page server of its own. Your host sends the same index.html for every address, and React builds each page in the browser. The [React SEO guide for Vite](https://vunora.ai/blog/vite-react-seo) shows that file and what it means for search. For picking a CMS, it means this:

- **Words read when Vite builds the app** are in the bundle. Changing one means a new build and a new deploy.
- **Words fetched in the browser** change as soon as the CMS publishes them. The key that fetches them ships to every visitor.

Vite's docs are plain about that second point. "Variables prefixed with `VITE_` will be exposed in client-side source code after Vite bundling." They add that "`VITE_*` variables should _not_ contain sensitive information such as API keys." So whatever CMS your pages fetch from, the key in your app must be one that can only read published content.

A Next.js app can also render pages on a server, which changes the choice. That side is in [how to give your marketing team a CMS for your Next.js site](https://vunora.ai/blog/nextjs-cms).

## Three places a React CMS can keep your words

### Files in your repo, read when Vite builds

You move the words out of your components into Markdown or JSON files, and a page reads them. Vite has a function for reading many files at once.

Vite's docs: "Vite supports importing multiple modules from the file system via the special `import.meta.glob` function". They also note: "This is a Vite-only feature and is not a web or ES standard." Built from the docs' own examples, reading every Markdown file in a folder as text looks like this:

```ts
// Every Markdown file in src/content, read as text when Vite builds the app
const posts = import.meta.glob('./content/*.md', {
  query: '?raw',
  import: 'default',
  eager: true,
})
```

A [git-based CMS](https://vunora.ai/glossary/git-based-cms) then gives your editors a screen over those files. Decap CMS puts it this way: "Content is stored in your Git repository alongside your code for easier versioning." Each save becomes a commit, and the site changes after your host builds it again.

### A headless CMS your pages fetch

A [headless CMS](https://vunora.ai/glossary/headless-cms) holds your content in its own store and hands it out through an API. Someone designs a content model, moves your words into it, and changes each component to fetch its entry in the browser with a read-only key.

Contentful says it straight: "The front end is always your responsibility." It fits best when the same content feeds more than one site or app. If you are not sure you need one, read [how to tell if you need a headless CMS](https://vunora.ai/blog/do-you-need-a-headless-cms).

### The components you already have

An editor can read the words where your components hold them today, and leave the components where they are. Vunora works this way. Nobody moves words into files or designs a content model first.

**Three places a React CMS keeps your words**

|                                | Files in your repo                               | Headless CMS                                                       | Vunora                                                 |
| ------------------------------ | ------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------ |
| Where the words live           | Markdown or JSON files next to your code         | The CMS's own store                                                | Vunora, with each publish also sent to your repo       |
| Work before the first edit     | Move the words out of your components into files | Design a content model, move the words in, fetch them on each page | Merge one import pull request                          |
| When an edit shows on the site | After your host builds the app again             | When you publish, if your pages fetch in the browser               | When you publish, through Vunora                       |
| Key in the browser             | None                                             | A read-only key you set up                                         | A read-only key for this one site, added by the import |

_From Vite's, Decap's and Contentful's own pages and from Vunora's import, read November 23, 2026._

## Questions to answer before you pick

**Before you pick a React CMS**

- Not done yet: Who edits the words, and how often? (A developer who changes a line once a month can keep the words in the code.)
- Not done yet: Where do the words sit today? (If they are inside your components, moving them out is most of the work for the first two ways.)
- Not done yet: Does the same content feed another site or an app? (Then a headless CMS built around a content model fits.)
- Not done yet: Does your host build the site again on each push? (Files in your repo depend on it.)
- Not done yet: Is the code in a GitHub repo?
- Not done yet: Does package.json list vite and react?

## Lovable and Bolt sites are React apps too

A site from an AI builder is often a Vite and React app in a GitHub repo, with its words written into the components.

- **Lovable.** Its docs say older apps are Vite and React: "Older React + Vite apps are pre-rendered for verified crawlers when they request a page." Newer ones are not: "Apps created from May 13, 2026 (June 22, 2026 on Enterprise plans) use TanStack Start with server-side rendering." Vunora imports Next.js, Vite with React, and TanStack Start, so a Lovable app of either kind fits.

* **Bolt.** Its docs say: "Every time you make a change that doesn't break the project, Bolt creates a commit for you." And: "It also checks GitHub every 30 seconds for any updates made outside Bolt and pulls those in."

Open `package.json` in the repo. If it lists `vite` and `react`, the site fits. Both builders keep writing to the repo after you add a CMS, so agree who changes what. [How to keep your Lovable or Bolt repo and let anyone edit it](https://vunora.ai/blog/your-lovable-or-bolt-site) covers two tools writing to one branch. For the three CMS routes on a Lovable site, with credits, read [how to add a CMS to your Lovable site](https://vunora.ai/blog/lovable-cms).

## How Vunora works on a Vite and React app

**From a Vite repo to a site your team edits**

1. **Connect GitHub and pick the repo** The analysis is read-only. Nothing is imported or written until you approve it.
2. **See whether your site fits** Vunora counts your pages and tells you which plan covers them, before you pay.
3. **Choose how edits reach GitHub** Save straight to your branch, or open a pull request for each page for a developer to review.
4. **Your developer merges the import pull request** It adds a helper and points each line of text at Vunora, with your original words kept as the fallback.
5. **Your team clicks a line, types and publishes** The page changes through Vunora, and the same words go to your repo.

_The import page shows each step._

The import pull request explains itself in its first lines. "It adds a generated helper module and replaces the words written into your pages with values read through `useFields(...)`." And: "If your site cannot reach Vunora, each field shows the words your page had before, so your build still works."

After the merge, your pages read their words in the browser, the way a headless CMS would. The helper reads them with a key that is read-only, covers this one site and can be revoked, so it is safe in your bundle. Your developer writes no fetch code.

A publish then works in two places at once. The editor tells you the page is "Live through Vunora". Vunora also sends the change to your branch as a commit, or opens a pull request if you chose that. If the branch is protected, Vunora opens a pull request instead. Your developer sees each change in the repo's history.

The import adds no server rendering, so your app still builds its pages in the browser. Vunora's [SEO checklist](https://vunora.ai/product/seo) runs after each import and each publish, and every Monday morning. On a site like this, it tells you the site builds its pages in the browser and marks which checks it can only run in Vunora. The [import page](https://vunora.ai/product/import) shows the whole flow.

## Where Vunora stops today

- It imports Next.js, Vite with React, and TanStack Start only, from a GitHub repo. Vite without React is not imported.
- It adds no server rendering or pre-rendering to a Vite app. That stays a developer's job.
- It does not host your site. Your host serves it as before.
- It does not build new screens or features. Those stay with your code, or with Lovable or Bolt.
- If you are planning content for a website and an app from one store, a headless CMS built around a content model is the plainer fit.

## What each way costs

Files in your repo cost your developer's time to move the words out of your components. A headless CMS charges by its own plan, and your developer's time pays for the content model and the fetch on each page. The [Contentful comparison](https://vunora.ai/blog/vunora-vs-contentful) lists how one of them charges, from its own pricing page.

Vunora charges for each site by the number of pages it finds, plus a seat for each person on your team. The [pricing page](https://vunora.ai/pricing) has every price, and you see yours before you pay.

## Questions

**Which CMS works with a React app?** Any of the three. A git-based CMS works with words in files, a headless CMS works through an API your components fetch, and Vunora works on the words already in your components.

**Can I use a headless CMS with Vite?** Yes. Your components fetch in the browser with a key that can only read published content, because Vite ships that key to every visitor.

**Do I have to move my words out of my components?** For files in your repo or a headless CMS, yes. With Vunora, no. The import reads them where they are.

**Is my Lovable or Bolt site a Vite app?** Open `package.json` in the repo. If it lists `vite` and `react`, yes. Newer Lovable apps use TanStack Start, which Vunora imports too.

**Does a React CMS help my SEO?** Not by itself. Where your words load in a Vite app decides what a crawler sees. Read [how to fix React SEO on a Vite single-page app](https://vunora.ai/blog/vite-react-seo).

## Sources

- Vite, env variables and modes, read November 23, 2026: <https://vite.dev/guide/env-and-mode>
- Vite, features: glob import, read November 23, 2026: <https://vite.dev/guide/features>
- Decap CMS, introduction, read November 23, 2026: <https://decapcms.org/docs/intro/>
- Contentful, what is a headless CMS, read November 23, 2026: <https://www.contentful.com/headless-cms/>
- Lovable, SEO and AI search, read November 23, 2026: <https://docs.lovable.dev/features/seo-aeo>
- Bolt, Git integration, read November 23, 2026: <https://support.bolt.new/integrations/git>

_Drafted with AI help and checked against the product._
