Guides

Deployment

Ship the static build to any host.

pnpm build produces a fully static site in dist/client — plain HTML, CSS, and JavaScript with no server component. Any static host works.

The output includes:

  • a prerendered index.html for every page
  • sitemap.xml (when $shiso.siteUrl is set)
  • redirect pages for every redirects rule
  • a .md copy of every page for AI tools
  • 404.html for hosts that serve it on unknown paths

GitHub Pages#

Point Pages at the build output with an action:

GitHub Pages serves 404.html for unknown paths automatically, so client-side routing keeps working on deep links.

Netlify#

  • Build command: pnpm build
  • Publish directory: dist/client

Vercel#

The repository includes vercel.json, which configures:

  • Build command: pnpm build
  • Framework preset: Other
  • Output directory: dist/client

Shiso prerenders its own routes, so Vercel serves it as a static site rather than applying generic Vite SPA routing. The output-directory override ensures Vercel serves the site nested in dist/client.

Cloudflare Pages#

  • Build command: pnpm build
  • Build output directory: dist/client

Deploying under a subpath#

When the site lives at https://example.com/my-docs/ rather than a domain root, pass Vite's --base flag to both build steps in the build script:

The prerenderer detects the base from the build output and lays out the directories to match.

Checklist#

  1. Set $shiso.siteUrl so canonical URLs, Open Graph tags, and the sitemap are emitted.
  2. Use a full-history checkout (fetch-depth: 0) if metadata.timestamp is enabled.
  3. Verify a deep link (any docs page URL) after the first deploy.
Last updated on