Astro + Vercel troubleshooting

Fix Astro Vercel Output Directory 404

Astro static sites normally output to dist, while SSR needs the correct Vercel adapter. Match the project mode to the deployment settings.

Common symptoms

  • Build succeeds but Vercel URL returns 404.
  • Static files exist locally in dist.
  • SSR routes fail or server output is missing.

What to check first

Platform: Astro + Vercel
Error: Output directory 404

Astro static sites normally output to dist, while SSR needs the correct Vercel adapter. Match the project mode to the deployment settings.

Step-by-step fix

  1. For static Astro, keep output static and verify dist is generated.
  2. For SSR, install and configure @astrojs/vercel.
  3. Check Vercel project output settings and framework detection.
  4. Redeploy after removing stale custom output settings.
// astro.config.mjs
import vercel from "@astrojs/vercel/serverless";
export default { output: "server", adapter: vercel() };

Common mistake to avoid

Do not configure SSR adapter for a purely static site unless you need server routes.

Still stuck?

Send the deploy log, repository link, target platform, and expected URL. ShipFast Deploy Rescue is a fixed-price debugging service for indie projects and MVPs.