Deneb ReactJs documentation
Deploy
Build the site and publish the out folder on Netlify, Cloudflare, Vercel, GitHub Pages or any static host.
Deneb React builds to plain HTML files. It needs no Node.js server on the host. You upload the out/ folder.
Before you build
- Set
urlincontent/site.ymlto your real address, with no slash at the end. Share links and social images use it. - Connect the contact form. See Forms and comments.
- Replace the demo text in
content/pages/privacy.md.
Build
npm run build
This writes the site to out/. Use npm run build, not next build alone, because the script after it makes link prefetching work on a static host. See Install and run.
Check the result on your computer with npm run start.
Settings for every host
| Setting | Value |
|---|---|
| Build command | npm run build |
| Output directory | out |
| Node version | 20 or newer |
Trailing slashes
The site uses trailing slashes: /about/ is the file out/about/index.html. Most hosts serve this without any setting. If a host redirects /about/ to /about or the other way round, turn that redirect off, or you may get a redirect loop. Keep the slash in every link you write, for example /contact/.
Missing pages show out/404.html. Netlify, Cloudflare Pages and GitHub Pages use this file on their own.
Netlify
Connect your repository, or drag the out folder onto Netlify. Set the build command to npm run build and the publish directory to out.
Cloudflare Pages
- Create a Pages project and connect your repository.
- Set the build command to
npm run buildand the output directory toout. - Deploy, then add your domain under Custom domains.
Cloudflare Workers (static assets)
You can also publish out/ as static assets on Workers. Build the site, then point the assets directory at out. In wrangler.jsonc:
{
"name": "my-site",
"compatibility_date": "2026-01-01",
"assets": { "directory": "./out" }
}
Then run:
npm run build
npx wrangler deploy
Vercel
Import the repository. Vercel detects Next.js and runs npm run build. Because next.config.mjs sets output: 'export', the finished site is the out folder. If Vercel asks, set the output directory to out.
GitHub Pages
- Add an empty file named
.nojekylltopublic/. The build copies it intoout/. Without it, GitHub Pages ignores the_nextfolder and the site loses its scripts. - Run
npm run build. - Publish the contents of
out/, for example with a GitHub Actions workflow that uploadsout/as the Pages artifact. In Settings, Pages, set the source to GitHub Actions.
The theme links to /assets/... and /about/ from the root of the site. It works on your-name.github.io or on a custom domain. It does not work as is on a project address such as your-name.github.io/repository.
Any other host
Run npm run build and upload everything inside out/ to the web root. Keep the _next and assets folders and the flat __next.*.txt files.