Skip to main content
StormyCMS

Starter structure

stormy init creates a pnpm and Turborepo workspace with two Next.js apps.

PathPurpose
apps/sitePublic site, port 3000
apps/adminPage editor, layout editor, and media library, port 4000
packages/components/src/libShared React components
packages/components/src/index.tsComponent export map and CMS field definitions
packages/components/src/styles.cssShared component styles
packages/theme/theme.cssSite theme and spacing tokens
packages/typesShared TypeScript declarations

Public site

apps/site/src/app/(pages)/[...slug]/page.tsx renders pages by slug and supplies document metadata.

The root route uses an empty slug. /company/about uses company/about. Missing pages redirect to /404.

The starter caches pages in memory. Restart the site to clear cached content. Review this policy before deployment.

Admin

RoutePurpose
/loginSign in with GitHub or Google
/pagesCreate and open pages
/pages/[id]Edit content, slug, and layout
/layoutsCreate and open layouts
/layouts/[id]Edit layout components and parent layout
/mediaUpload and manage files

Both apps import components. Register new components through Components and schema.

Deploy

Build with pnpm build. Deploy apps/site and apps/admin as separate Next.js applications with their own environment variables.

Replace the localhost URLs in each app's .env.example with production URLs. Register the production admin callback URL in the account portal. Configure media storage if editors upload files.

Last updated: 10/20/26, 1:09 AM

StormyCMS

The headless CMS where you own the editor.