Platform root — step 1 skeleton

The dashboard, editor, and billing land here later.

This page is what visitors see on your root domain. Every other hostname — subdomains you hand out, or custom domains customers point at you — gets routed by middleware.ts to the tenant renderer instead, without a separate deployment per site.

Visit demo.localhost:3000 in your browser to see a tenant site rendered from JSON. Modern browsers resolve *.localhost to your machine automatically — no DNS or hosts file editing needed.

To see the fully-custom-domain path (a hostname that isn't a subdomain of this root at all — standing in for a domain a customer pointed at you), curl it with a spoofed Host header:

curl -H 'Host: acme.test' http://localhost:3000/

In production, ROOT_DOMAIN becomes your real domain, subdomains resolve via a wildcard DNS record, and custom domains get attached per-tenant through the Vercel Domains API — same middleware, same renderer, no code changes.

Mock tenant (subdomain)demo.localhost:3000
Mock tenant (custom domain)acme.test