deploy.ccSelf-hosting deploy handbook
deploy.cc / Guides / Astro

Astro deploy guide

Astro outputs static files to dist/ by default; add an adapter for on-demand rendering.

Build
npm run build
Output
dist/
Official docs
Astro Deploy guides · On-demand rendering adapters

How to deploy

  1. Static: npm run build and upload dist/.
  2. GitHub Pages: use the official Actions workflow; set site and base.
  3. SSR: npx astro add node (or cloudflare / vercel / netlify), then build.

Per platform

PlatformNotes
Cloudflare Pages / Netlify / VercelBuild npm run build, output dist.
GitHub PagesUse our GitHub Pages workflow with output dist.

Notes

Generate a config