[{"data":1,"prerenderedAt":103},["ShallowReactive",2],{"seo-verification":3,"marketplace-app-en-sveltekit-stack":6},{"google":4,"bing":5},"EycwPY2XMyTkVzas3n1ygeNJFGAH513qrMjfDljzsMQ","",{"slug":7,"slugs":8,"categorySlugs":9,"name":13,"description":14,"phase":15,"unavailableReason":16,"docsUrl":17,"logo":16,"github":16,"tagline":18,"longDescription":19,"features":20,"useCases":27,"steps":37,"faq":53,"specs":69,"compatibleOs":76,"relatedApps":77,"relatedPosts":97,"category":100},"sveltekit-stack",{"fr":7,"en":7,"ar":7},{"fr":10,"en":11,"ar":12},"developpement","development","التطوير","SvelteKit Stack","Node.js LTS, PM2 and Nginx preconfigured for SvelteKit. Deploy your app in SSR or static mode on your own VPS in production.",1,null,"https:\u002F\u002Fservorbit.com\u002Fblog\u002Fdeploying-a-sveltekit-application-on-a-vps","SvelteKit Stack — Node.js LTS, PM2 and Nginx preconfigured for SSR or static SvelteKit production deployments.","SvelteKit Stack provisions your VPS with the complete toolchain a SvelteKit project needs in production: Node.js LTS from the official NodeSource repository, PM2 for zero-downtime process management, and Nginx as the TLS-terminating reverse proxy.\n\nSvelteKit's adapter-node produces a standalone Node server — a persistent process that keeps database connections open and responds without cold starts. Form actions, server-side `load` functions, and `+server.ts` endpoints all run in a single runtime you control. Unlike serverless deployments, you avoid per-invocation billing and execution time limits.",[21,22,23,24,25,26],"Node.js LTS from the official NodeSource repository — the current stable release, not the outdated distro package.","PM2 process manager — zero-downtime reloads, log rotation, startup scripts, and cluster mode for multi-core VPS.","Nginx reverse proxy with gzip compression and long-lived Cache-Control headers for versioned static assets.","Compatible with SvelteKit's `@sveltejs\u002Fadapter-node` for standalone SSR and `adapter-static` for fully pre-rendered sites.","No cold starts — the Node server process is persistent, keeping database connections pooled between requests.","WebSockets and SSE supported, enabling real-time features that serverless platforms restrict or complicate.",[28,31,34],{"title":29,"body":30},"SSR web application","Deploy a full SvelteKit app with form actions, server-side `load` functions, and API endpoints. PM2 supervises the Node process with automatic restart and zero-downtime reloads between deployments.",{"title":32,"body":33},"Static site hosting","Build your project with `adapter-static`, upload the `build\u002F` folder, and serve it from Nginx with no Node process running. Near-zero memory footprint and instant response times.",{"title":35,"body":36},"API backend for a SvelteKit frontend","Co-host your SvelteKit frontend and a REST API on the same VPS. Nginx routes `\u002Fapi\u002F*` requests to a separate service while SvelteKit handles everything else — all behind a single TLS-terminated domain.",[38,41,44,47,50],{"title":39,"body":40},"Create the VPS","Select the SvelteKit Stack template. 1 GB RAM is sufficient for a static site; 2 GB for SSR with PM2 and a co-hosted database.",{"title":42,"body":43},"Configure the adapter","In `svelte.config.js`, set `adapter: node()` from `@sveltejs\u002Fadapter-node` for SSR, or `adapter: static()` from `@sveltejs\u002Fadapter-static` for a fully pre-rendered site.",{"title":45,"body":46},"First access","This template installs a toolchain (Node.js LTS, PM2, Nginx). There is no web interface to open — connect via SSH and deploy your own SvelteKit project.",{"title":48,"body":49},"Build and deploy","Run `npm run build` locally or in CI. Transfer the `build\u002F` folder to the VPS and start with `pm2 start build\u002Findex.js --name svelte-app`. Set `ORIGIN=https:\u002F\u002Fyourdomain.com` — required for form action CSRF validation.",{"title":51,"body":52},"Configure Nginx","Proxy requests to `http:\u002F\u002F127.0.0.1:3000` with appropriate `proxy_set_header` directives. Enable `proxy_http_version 1.1` and the `Upgrade` header if your app uses WebSockets. Obtain a Let's Encrypt certificate with Certbot.",[54,57,60,63,66],{"q":55,"a":56},"What is the difference between SvelteKit Stack and Astro Stack?","Both install Node.js LTS, PM2, and Nginx. SvelteKit targets reactive web applications with form actions, server-side `load` functions, and real-time features. Astro targets content sites and hybrid rendering — it ships zero JavaScript by default and runs a lighter Node process for SSR pages.",{"q":58,"a":59},"Can I deploy a fully static SvelteKit site?","Yes. Configure `@sveltejs\u002Fadapter-static`, build your project, and serve the `build\u002F` folder from Nginx. No Node process runs at runtime — Nginx serves static files directly with minimal resource usage.",{"q":61,"a":62},"How do I handle environment variables in production?","Pass environment variables to PM2 via an ecosystem config file or directly on the command line: `pm2 start build\u002Findex.js --env production`. SvelteKit reads them at startup. `ORIGIN` is mandatory — form actions reject requests if it does not match the actual URL.",{"q":64,"a":65},"Can I host multiple SvelteKit apps on the same VPS?","Yes. Run each app as a separate PM2 process on a different internal port (3000, 3001, etc.). Nginx routes requests by domain or path using separate `server {}` blocks or `location` rules.",{"q":67,"a":68},"What minimum RAM do you recommend for SSR?","2 GB of RAM is a comfortable baseline for a single SvelteKit SSR app. If you co-host a database or add multiple PM2 workers in cluster mode, plan for at least 4 GB.",{"ram":70,"cpu":71,"stack":72},"1 GB (static), 2 GB (SSR)","1 vCPU",[73,74,75],"Node.js LTS","PM2","Nginx",[],[78,85,91],{"name":79,"slug":80,"categorySlug":11,"categoryName":81,"categoryColor":82,"logo":16,"tagline":83,"description":84},"Astro Stack","astro-stack","Development","text-warning bg-warning\u002F10","Astro Stack — Node.js LTS, PM2 and Nginx preconfigured for static or SSR Astro deployments.","Node.js LTS, PM2 and Nginx preconfigured for Astro. Deploy your SSR or static Astro sites on your own infrastructure.",{"name":86,"slug":87,"categorySlug":11,"categoryName":81,"categoryColor":82,"logo":88,"tagline":89,"description":90},"Node.js Stack","nodejs-stack","https:\u002F\u002Fcdn.simpleicons.org\u002Fnodedotjs","Node.js, PM2, Nginx and a database — a production environment for your JavaScript APIs and apps.","Node.js with PM2, an Nginx reverse proxy and a database. Your JavaScript APIs and applications ready to take traffic.",{"name":92,"slug":93,"categorySlug":11,"categoryName":81,"categoryColor":82,"logo":94,"tagline":95,"description":96},"Nuxt Stack","nuxt-stack","https:\u002F\u002Fcdn.simpleicons.org\u002Fnuxt","Nuxt 3 with SSR, PostgreSQL and a reverse proxy — a production environment for your Vue.js apps.","Nuxt 3 with SSR, PostgreSQL and a reverse proxy. A production environment for your Vue.js applications.",[98,99],"deployer-sveltekit-vps","deployer-astro-vps",{"key":10,"slug":11,"name":81,"objective":101,"icon":102,"color":82},"Kick off a software project quickly.","dev",1787581041601]