curl -I https://sveleton.ramilkarimov.me/nonexistent/ returns HTTP/2 200 with the prerendered 200.html body. Same for /robots.txt and /sitemap.xml, which do not exist. Search engines treat this as soft 404 and may index the fallback page under arbitrary URLs.

The site is fully prerendered, so there is no reason for an SPA fallback at all. adapter-static is configured with fallback: '200.html' in vite.config.js, and the repo root also carries a placeholder 200.html with the text "Document" that nothing uses.

Tasks

  • Drop fallback from the adapter config and delete the root 200.html
  • Prerender +error.svelte as 404.html and point nginx error_page 404 at it; use try_files $uri $uri/index.html =404
  • Add the nginx server block to the repo (or at least to the README) so the deploy is reproducible
  • Verify with curl that unknown paths return 404 and robots.txt returns text/plain

Real 404s

Crawlers should not index the fallback page

A static site template built with SvelteKit.

Sveleton, 2025